mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-30 17:01:08 +02:00
CLuaInstance: Add script function 'channelRezap'
- Alternative rezap method for movie plugins
- Set Lua api version to 1.21
Origin commit data
------------------
Branch: ni/coolstream
Commit: b9afbb1e2c
Author: Michael Liebmann <tuxcode.bbg@gmail.com>
Date: 2015-12-08 (Tue, 08 Dec 2015)
------------------
This commit was generated by Migit
This commit is contained in:
@@ -3547,13 +3547,8 @@ void CNeutrinoApp::tvMode( bool rezap )
|
||||
|
||||
g_RemoteControl->tvMode();
|
||||
SetChannelMode(g_settings.channel_mode);
|
||||
if( rezap ) {
|
||||
t_channel_id last_chid = CZapit::getInstance()->GetLastTVChannel();
|
||||
if(CServiceManager::getInstance()->FindChannel(last_chid))
|
||||
channelList->zapTo_ChannelID(last_chid, true); /* force re-zap */
|
||||
else
|
||||
channelList->zapTo(0, true);
|
||||
}
|
||||
if( rezap )
|
||||
channelRezap();
|
||||
#ifdef USEACTIONLOG
|
||||
g_ActionLog->println("mode: tv");
|
||||
#endif
|
||||
@@ -3778,16 +3773,27 @@ void CNeutrinoApp::radioMode( bool rezap)
|
||||
if (g_settings.radiotext_enable && !g_Radiotext)
|
||||
g_Radiotext = new CRadioText;
|
||||
|
||||
if( rezap ) {
|
||||
t_channel_id last_chid = CZapit::getInstance()->GetLastRADIOChannel();
|
||||
if(CServiceManager::getInstance()->FindChannel(last_chid))
|
||||
channelList->zapTo_ChannelID(last_chid, true); /* force re-zap */
|
||||
else
|
||||
channelList->zapTo(0, true); /* force re-zap */
|
||||
}
|
||||
if( rezap )
|
||||
channelRezap();
|
||||
frameBuffer->showFrame("radiomode.jpg");
|
||||
}
|
||||
|
||||
void CNeutrinoApp::channelRezap()
|
||||
{
|
||||
t_channel_id last_chid = 0;
|
||||
if (mode == mode_tv)
|
||||
last_chid = CZapit::getInstance()->GetLastTVChannel();
|
||||
else if (mode == mode_radio)
|
||||
last_chid = CZapit::getInstance()->GetLastRADIOChannel();
|
||||
else
|
||||
return;
|
||||
|
||||
if(CServiceManager::getInstance()->FindChannel(last_chid))
|
||||
channelList->zapTo_ChannelID(last_chid, true);
|
||||
else
|
||||
channelList->zapTo(0, true);
|
||||
}
|
||||
|
||||
//switching from current mode to tv or radio mode or to optional parameter prev_mode
|
||||
void CNeutrinoApp::switchTvRadioMode(const int prev_mode)
|
||||
{
|
||||
|
Reference in New Issue
Block a user