From fce20e73eaba1161ec29a47040d5617cbe8775a8 Mon Sep 17 00:00:00 2001 From: vanhofen Date: Wed, 19 Oct 2016 10:06:35 +0200 Subject: [PATCH] bouqueteditor_chanselect: use getItemColors function Origin commit data ------------------ Branch: ni/coolstream Commit: https://github.com/neutrino-images/ni-neutrino/commit/2040d7558ac57713930e1d7c09c3f0e1d9880030 Author: vanhofen Date: 2016-10-19 (Wed, 19 Oct 2016) Origin message was: ------------------ - bouqueteditor_chanselect: use getItemColors function ------------------ No further description and justification available within origin commit message! ------------------ This commit was generated by Migit --- src/gui/bedit/bouqueteditor_chanselect.cpp | 23 +++++++++++----------- 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/src/gui/bedit/bouqueteditor_chanselect.cpp b/src/gui/bedit/bouqueteditor_chanselect.cpp index 4ec7621fc..91e26dff3 100644 --- a/src/gui/bedit/bouqueteditor_chanselect.cpp +++ b/src/gui/bedit/bouqueteditor_chanselect.cpp @@ -106,33 +106,32 @@ bool CBEChannelSelectWidget::hasChanged() void CBEChannelSelectWidget::paintItem(uint32_t itemNr, int paintNr, bool pselected) { int ypos = y+ theight + paintNr*iheight; + int i_radius = RADIUS_NONE; fb_pixel_t color; fb_pixel_t bgcolor; + + getItemColors(color, bgcolor, pselected); + if (pselected) { - color = COL_MENUCONTENTSELECTED_TEXT; - bgcolor = COL_MENUCONTENTSELECTED_PLUS_0; - - if(itemNr < getItemCount()) { + if (itemNr < getItemCount()) + { initItem2DetailsLine (paintNr, itemNr); paintDetails(itemNr); } - - frameBuffer->paintBoxRel(x,ypos, width- 15, iheight, COL_MENUCONTENT_PLUS_0); - frameBuffer->paintBoxRel(x,ypos, width- 15, iheight, bgcolor, RADIUS_LARGE); + i_radius = RADIUS_LARGE; } else { if (itemNr < getItemCount() && (Channels[itemNr]->flags & CZapitChannel::NOT_PRESENT)) color = COL_MENUCONTENTINACTIVE_TEXT; - else - color = COL_MENUCONTENT_TEXT; - - bgcolor = COL_MENUCONTENT_PLUS_0; - frameBuffer->paintBoxRel(x,ypos, width- 15, iheight, bgcolor); } + if (i_radius) + frameBuffer->paintBoxRel(x,ypos, width- 15, iheight, COL_MENUCONTENT_PLUS_0); + frameBuffer->paintBoxRel(x,ypos, width- 15, iheight, bgcolor, i_radius); + if(itemNr < getItemCount()) { if( isChannelInBouquet(itemNr))