mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-09-01 01:41:12 +02:00
infoviewer_bb: don't paint deactivated buttons
Origin commit data
------------------
Branch: ni/coolstream
Commit: 47eb2e27ec
Author: vanhofen <vanhofen@gmx.de>
Date: 2015-12-14 (Mon, 14 Dec 2015)
Origin message was:
------------------
- infoviewer_bb: don't paint deactivated buttons
------------------
No further description and justification available within origin commit message!
------------------
This commit was generated by Migit
This commit is contained in:
@@ -213,12 +213,14 @@ void CInfoViewerBB::getBBButtonInfo()
|
|||||||
bbButtonMaxX = g_InfoViewer->ChanInfoX;
|
bbButtonMaxX = g_InfoViewer->ChanInfoX;
|
||||||
int bbButtonMaxW = 0;
|
int bbButtonMaxW = 0;
|
||||||
int mode = NeutrinoMessages::mode_unknown;
|
int mode = NeutrinoMessages::mode_unknown;
|
||||||
|
int pers = -1;
|
||||||
for (int i = 0; i < CInfoViewerBB::BUTTON_MAX; i++) {
|
for (int i = 0; i < CInfoViewerBB::BUTTON_MAX; i++) {
|
||||||
int w = 0, h = 0;
|
int w = 0, h = 0;
|
||||||
bool active;
|
bool active;
|
||||||
std::string text, icon;
|
std::string text, icon;
|
||||||
switch (i) {
|
switch (i) {
|
||||||
case CInfoViewerBB::BUTTON_RED:
|
case CInfoViewerBB::BUTTON_RED:
|
||||||
|
pers = SNeutrinoSettings::P_MAIN_RED_BUTTON;
|
||||||
icon = NEUTRINO_ICON_BUTTON_RED;
|
icon = NEUTRINO_ICON_BUTTON_RED;
|
||||||
frameBuffer->getIconSize(icon.c_str(), &w, &h);
|
frameBuffer->getIconSize(icon.c_str(), &w, &h);
|
||||||
mode = CNeutrinoApp::getInstance()->getMode();
|
mode = CNeutrinoApp::getInstance()->getMode();
|
||||||
@@ -235,6 +237,7 @@ void CInfoViewerBB::getBBButtonInfo()
|
|||||||
text = g_Locale->getText(LOCALE_INFOVIEWER_EVENTLIST);
|
text = g_Locale->getText(LOCALE_INFOVIEWER_EVENTLIST);
|
||||||
break;
|
break;
|
||||||
case CInfoViewerBB::BUTTON_GREEN:
|
case CInfoViewerBB::BUTTON_GREEN:
|
||||||
|
pers = SNeutrinoSettings::P_MAIN_GREEN_BUTTON;
|
||||||
icon = NEUTRINO_ICON_BUTTON_GREEN;
|
icon = NEUTRINO_ICON_BUTTON_GREEN;
|
||||||
frameBuffer->getIconSize(icon.c_str(), &w, &h);
|
frameBuffer->getIconSize(icon.c_str(), &w, &h);
|
||||||
mode = CNeutrinoApp::getInstance()->getMode();
|
mode = CNeutrinoApp::getInstance()->getMode();
|
||||||
@@ -259,6 +262,7 @@ void CInfoViewerBB::getBBButtonInfo()
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case CInfoViewerBB::BUTTON_YELLOW:
|
case CInfoViewerBB::BUTTON_YELLOW:
|
||||||
|
pers = SNeutrinoSettings::P_MAIN_YELLOW_BUTTON;
|
||||||
icon = NEUTRINO_ICON_BUTTON_YELLOW;
|
icon = NEUTRINO_ICON_BUTTON_YELLOW;
|
||||||
frameBuffer->getIconSize(icon.c_str(), &w, &h);
|
frameBuffer->getIconSize(icon.c_str(), &w, &h);
|
||||||
mode = CNeutrinoApp::getInstance()->getMode();
|
mode = CNeutrinoApp::getInstance()->getMode();
|
||||||
@@ -275,6 +279,7 @@ void CInfoViewerBB::getBBButtonInfo()
|
|||||||
text = g_Locale->getText((g_RemoteControl->are_subchannels) ? LOCALE_INFOVIEWER_SUBSERVICE : LOCALE_INFOVIEWER_SELECTTIME);
|
text = g_Locale->getText((g_RemoteControl->are_subchannels) ? LOCALE_INFOVIEWER_SUBSERVICE : LOCALE_INFOVIEWER_SELECTTIME);
|
||||||
break;
|
break;
|
||||||
case CInfoViewerBB::BUTTON_BLUE:
|
case CInfoViewerBB::BUTTON_BLUE:
|
||||||
|
pers = SNeutrinoSettings::P_MAIN_BLUE_BUTTON;
|
||||||
icon = NEUTRINO_ICON_BUTTON_BLUE;
|
icon = NEUTRINO_ICON_BUTTON_BLUE;
|
||||||
frameBuffer->getIconSize(icon.c_str(), &w, &h);
|
frameBuffer->getIconSize(icon.c_str(), &w, &h);
|
||||||
mode = CNeutrinoApp::getInstance()->getMode();
|
mode = CNeutrinoApp::getInstance()->getMode();
|
||||||
@@ -298,6 +303,8 @@ void CInfoViewerBB::getBBButtonInfo()
|
|||||||
bbButtonInfo[i].h = h;
|
bbButtonInfo[i].h = h;
|
||||||
bbButtonInfo[i].text = text;
|
bbButtonInfo[i].text = text;
|
||||||
bbButtonInfo[i].icon = icon;
|
bbButtonInfo[i].icon = icon;
|
||||||
|
if (pers > -1 && (g_settings.personalize[pers] != CPersonalizeGui::PERSONALIZE_ACTIVE_MODE_ENABLED))
|
||||||
|
active = false;
|
||||||
bbButtonInfo[i].active = active;
|
bbButtonInfo[i].active = active;
|
||||||
}
|
}
|
||||||
// Calculate position/size of buttons
|
// Calculate position/size of buttons
|
||||||
|
Reference in New Issue
Block a user