mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-30 17:01:08 +02:00
neutrino: unify modes handling; ...
remove double enum from CNeutrinoApp and move mostly used enum from NeutrinoMessages to new NeutrinoModes
Origin commit data
------------------
Branch: ni/coolstream
Commit: 028ec3cf3c
Author: vanhofen <vanhofen@gmx.de>
Date: 2017-11-20 (Mon, 20 Nov 2017)
Origin message was:
------------------
- neutrino: unify modes handling; ...
remove double enum from CNeutrinoApp and move mostly used enum from NeutrinoMessages to new NeutrinoModes
------------------
This commit was generated by Migit
This commit is contained in:
@@ -166,7 +166,7 @@ void CInfoViewerBB::getBBIconInfo()
|
||||
BBarY = g_InfoViewer->BoxEndY + bottom_bar_offset;
|
||||
BBarFontY = BBarY + InfoHeightY_Info - (InfoHeightY_Info - g_Font[SNeutrinoSettings::FONT_TYPE_MENU_FOOT]->getHeight()) / 2; /* center in buttonbar */
|
||||
bbIconMinX = g_InfoViewer->BoxEndX - OFFSET_INNER_MID;
|
||||
bool isRadioMode = (CNeutrinoApp::getInstance()->getMode() == NeutrinoMessages::mode_radio || CNeutrinoApp::getInstance()->getMode() == NeutrinoMessages::mode_webradio);
|
||||
bool isRadioMode = (CNeutrinoApp::getInstance()->getMode() == NeutrinoModes::mode_radio || CNeutrinoApp::getInstance()->getMode() == NeutrinoModes::mode_webradio);
|
||||
|
||||
for (int i = 0; i < CInfoViewerBB::ICON_MAX; i++) {
|
||||
int w = 0, h = 0;
|
||||
@@ -230,7 +230,7 @@ void CInfoViewerBB::getBBButtonInfo()
|
||||
bbButtonMaxH = 0;
|
||||
bbButtonMaxX = g_InfoViewer->ChanInfoX;
|
||||
int bbButtonMaxW = 0;
|
||||
int mode = NeutrinoMessages::mode_unknown;
|
||||
int mode = NeutrinoModes::mode_unknown;
|
||||
int pers = -1;
|
||||
for (int i = 0; i < CInfoViewerBB::BUTTON_MAX; i++) {
|
||||
int w = 0, h = 0;
|
||||
@@ -242,7 +242,7 @@ void CInfoViewerBB::getBBButtonInfo()
|
||||
icon = NEUTRINO_ICON_BUTTON_RED;
|
||||
frameBuffer->getIconSize(icon.c_str(), &w, &h);
|
||||
mode = CNeutrinoApp::getInstance()->getMode();
|
||||
if (mode == NeutrinoMessages::mode_ts) {
|
||||
if (mode == NeutrinoModes::mode_ts) {
|
||||
text = CKeybindSetup::getMoviePlayerButtonName(CRCInput::RC_red, active, g_settings.infobar_buttons_usertitle);
|
||||
if (!text.empty())
|
||||
break;
|
||||
@@ -257,7 +257,7 @@ void CInfoViewerBB::getBBButtonInfo()
|
||||
icon = NEUTRINO_ICON_BUTTON_GREEN;
|
||||
frameBuffer->getIconSize(icon.c_str(), &w, &h);
|
||||
mode = CNeutrinoApp::getInstance()->getMode();
|
||||
if (mode == NeutrinoMessages::mode_ts) {
|
||||
if (mode == NeutrinoModes::mode_ts) {
|
||||
text = CKeybindSetup::getMoviePlayerButtonName(CRCInput::RC_green, active, g_settings.infobar_buttons_usertitle);
|
||||
if (!text.empty())
|
||||
break;
|
||||
@@ -272,7 +272,7 @@ void CInfoViewerBB::getBBButtonInfo()
|
||||
icon = NEUTRINO_ICON_BUTTON_YELLOW;
|
||||
frameBuffer->getIconSize(icon.c_str(), &w, &h);
|
||||
mode = CNeutrinoApp::getInstance()->getMode();
|
||||
if (mode == NeutrinoMessages::mode_ts) {
|
||||
if (mode == NeutrinoModes::mode_ts) {
|
||||
text = CKeybindSetup::getMoviePlayerButtonName(CRCInput::RC_yellow, active, g_settings.infobar_buttons_usertitle);
|
||||
if (!text.empty())
|
||||
break;
|
||||
@@ -287,7 +287,7 @@ void CInfoViewerBB::getBBButtonInfo()
|
||||
icon = NEUTRINO_ICON_BUTTON_BLUE;
|
||||
frameBuffer->getIconSize(icon.c_str(), &w, &h);
|
||||
mode = CNeutrinoApp::getInstance()->getMode();
|
||||
if (mode == NeutrinoMessages::mode_ts) {
|
||||
if (mode == NeutrinoModes::mode_ts) {
|
||||
text = CKeybindSetup::getMoviePlayerButtonName(CRCInput::RC_blue, active, g_settings.infobar_buttons_usertitle);
|
||||
if (!text.empty())
|
||||
break;
|
||||
@@ -301,7 +301,7 @@ void CInfoViewerBB::getBBButtonInfo()
|
||||
break;
|
||||
}
|
||||
//label audio control button in movieplayer mode
|
||||
if (mode == NeutrinoMessages::mode_ts && !CMoviePlayerGui::getInstance().timeshift)
|
||||
if (mode == NeutrinoModes::mode_ts && !CMoviePlayerGui::getInstance().timeshift)
|
||||
{
|
||||
if (text == g_Locale->getText(LOCALE_MPKEY_AUDIO) && !g_settings.infobar_buttons_usertitle)
|
||||
text = CMoviePlayerGui::getInstance(false).CurrentAudioName(); // use instance_mp
|
||||
@@ -596,7 +596,7 @@ void CInfoViewerBB::showIcon_Resolution()
|
||||
{
|
||||
if ((!is_visible) || (g_settings.infobar_show_res == 2)) //show resolution icon is off
|
||||
return;
|
||||
if (CNeutrinoApp::getInstance()->getMode() == NeutrinoMessages::mode_radio || CNeutrinoApp::getInstance()->getMode() == NeutrinoMessages::mode_webradio)
|
||||
if (CNeutrinoApp::getInstance()->getMode() == NeutrinoModes::mode_radio || CNeutrinoApp::getInstance()->getMode() == NeutrinoModes::mode_webradio)
|
||||
return;
|
||||
const char *icon_name = NULL;
|
||||
#if 0
|
||||
@@ -677,7 +677,7 @@ void CInfoViewerBB::showOne_CAIcon()
|
||||
{
|
||||
std::string sIcon = "";
|
||||
#if 0
|
||||
if (CNeutrinoApp::getInstance()->getMode() != NeutrinoMessages::mode_radio) {
|
||||
if (CNeutrinoApp::getInstance()->getMode() != NeutrinoModes::mode_radio) {
|
||||
if (scrambledNoSig)
|
||||
sIcon = NEUTRINO_ICON_SCRAMBLED2_BLANK;
|
||||
else {
|
||||
@@ -830,7 +830,7 @@ void CInfoViewerBB::showIcon_CA_Status(int notfirst)
|
||||
|
||||
if (g_settings.infobar_casystem_display == 3)
|
||||
return;
|
||||
if(NeutrinoMessages::mode_ts == CNeutrinoApp::getInstance()->getMode() && !CMoviePlayerGui::getInstance().timeshift){
|
||||
if(NeutrinoModes::mode_ts == CNeutrinoApp::getInstance()->getMode() && !CMoviePlayerGui::getInstance().timeshift){
|
||||
if (g_settings.infobar_casystem_display == 2) {
|
||||
fta = true;
|
||||
showOne_CAIcon();
|
||||
|
Reference in New Issue
Block a user