mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-29 00:11:14 +02:00
- neutrino/channellist: avoid double code
Signed-off-by: Thilo Graf <dbt@novatux.de>
This commit is contained in:
@@ -937,30 +937,21 @@ int CChannelList::show()
|
||||
}
|
||||
fclose(f);
|
||||
}
|
||||
if (!bm12) {
|
||||
if (!bm12)
|
||||
ShowMsg(LOCALE_MESSAGEBOX_ERROR, LOCALE_BOXMODE12_NOT_ACTIVATED, CMsgBox::mbrOk, CMsgBox::mbOk, NEUTRINO_ICON_ERROR);
|
||||
} else {
|
||||
if(SameTP()) {
|
||||
if (CZapit::getInstance()->GetPipChannelID() == (*chanlist)[selected]->getChannelID()) {
|
||||
g_Zapit->stopPip();
|
||||
calcSize();
|
||||
paintBody();
|
||||
} else {
|
||||
handleMsg(NeutrinoMessages::EVT_PROGRAMLOCKSTATUS, 0x100, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
#else
|
||||
if(SameTP()) {
|
||||
if (CZapit::getInstance()->GetPipChannelID() == (*chanlist)[selected]->getChannelID()) {
|
||||
g_Zapit->stopPip();
|
||||
calcSize();
|
||||
paintBody();
|
||||
} else {
|
||||
handleMsg(NeutrinoMessages::EVT_PROGRAMLOCKSTATUS, 0x100, true);
|
||||
}
|
||||
}
|
||||
else
|
||||
#endif
|
||||
{
|
||||
if(SameTP()) {
|
||||
if (CZapit::getInstance()->GetPipChannelID() == (*chanlist)[selected]->getChannelID()) {
|
||||
g_Zapit->stopPip();
|
||||
calcSize();
|
||||
paintBody();
|
||||
} else {
|
||||
handleMsg(NeutrinoMessages::EVT_PROGRAMLOCKSTATUS, 0x100, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
else if (!empty && ((msg == CRCInput::RC_info) || (msg == CRCInput::RC_help))) {
|
||||
|
@@ -3291,22 +3291,17 @@ void CNeutrinoApp::RealRun()
|
||||
}
|
||||
fclose(f);
|
||||
}
|
||||
if (!bm12) {
|
||||
if (!bm12)
|
||||
ShowMsg(LOCALE_MESSAGEBOX_ERROR, LOCALE_BOXMODE12_NOT_ACTIVATED, CMsgBox::mbrOk, CMsgBox::mbOk, NEUTRINO_ICON_ERROR);
|
||||
} else {
|
||||
else
|
||||
#endif
|
||||
{
|
||||
t_channel_id pip_channel_id = CZapit::getInstance()->GetPipChannelID();
|
||||
if (pip_channel_id)
|
||||
g_Zapit->stopPip();
|
||||
else
|
||||
StartPip(CZapit::getInstance()->GetCurrentChannelID());
|
||||
}
|
||||
#else
|
||||
t_channel_id pip_channel_id = CZapit::getInstance()->GetPipChannelID();
|
||||
if (pip_channel_id)
|
||||
g_Zapit->stopPip();
|
||||
else
|
||||
StartPip(CZapit::getInstance()->GetCurrentChannelID());
|
||||
#endif
|
||||
}
|
||||
else if (msg == (neutrino_msg_t) g_settings.key_pip_setup) {
|
||||
CPipSetup pipsetup;
|
||||
|
Reference in New Issue
Block a user