neutrino.cpp: remove firstChannel()

This commit is contained in:
[CST] Focus
2012-04-10 16:40:09 +04:00
parent 145a751dbe
commit 4abcb24346
2 changed files with 6 additions and 16 deletions

View File

@@ -1144,14 +1144,6 @@ void CNeutrinoApp::saveSetup(const char * fname)
} }
} }
/**************************************************************************************
* CNeutrinoApp - firstChannel, get the initial channel *
**************************************************************************************/
void CNeutrinoApp::firstChannel()
{
g_Zapit->getLastChannel(firstchannel.channel_id, firstchannel.mode);
}
/************************************************************************************** /**************************************************************************************
* CNeutrinoApp - channelsInit, get the Channellist from daemon * * CNeutrinoApp - channelsInit, get the Channellist from daemon *
**************************************************************************************/ **************************************************************************************/
@@ -3135,10 +3127,10 @@ void CNeutrinoApp::tvMode( bool rezap )
g_RemoteControl->tvMode(); g_RemoteControl->tvMode();
SetChannelMode(g_settings.channel_mode); SetChannelMode(g_settings.channel_mode);
if( rezap ) { if( rezap ) {
firstChannel(); t_channel_id last_chid = CZapit::getInstance()->GetLastTVChannel();
channelList->setSelected(0xfffffff); /* make sure that zapTo_ChannelID will zap */ channelList->setSelected(0xfffffff); /* make sure that zapTo_ChannelID will zap */
if(CServiceManager::getInstance()->FindChannel(firstchannel.channel_id)) if(CServiceManager::getInstance()->FindChannel(last_chid))
channelList->zapTo_ChannelID( firstchannel.channel_id ); channelList->zapTo_ChannelID(last_chid);
else else
channelList->zapTo(0); channelList->zapTo(0);
} }
@@ -3342,10 +3334,10 @@ void CNeutrinoApp::radioMode( bool rezap)
g_RemoteControl->radioMode(); g_RemoteControl->radioMode();
SetChannelMode(g_settings.channel_mode_radio); SetChannelMode(g_settings.channel_mode_radio);
if( rezap ) { if( rezap ) {
firstChannel(); t_channel_id last_chid = CZapit::getInstance()->GetLastRADIOChannel();
channelList->setSelected(0xfffffff); /* make sure that zapTo_ChannelID will zap */ channelList->setSelected(0xfffffff); /* make sure that zapTo_ChannelID will zap */
if(CServiceManager::getInstance()->FindChannel(firstchannel.channel_id)) if(CServiceManager::getInstance()->FindChannel(last_chid))
channelList->zapTo_ChannelID( firstchannel.channel_id ); channelList->zapTo_ChannelID(last_chid);
else else
channelList->zapTo(0); channelList->zapTo(0);
} }

View File

@@ -116,7 +116,6 @@ private:
int lastChannelMode; int lastChannelMode;
struct timeval standby_pressed_at; struct timeval standby_pressed_at;
CZapitClient::responseGetLastChannel firstchannel;
st_rmsg sendmessage; st_rmsg sendmessage;
int current_muted; int current_muted;
@@ -129,7 +128,6 @@ private:
CIPChangeNotifier *MyIPChanger; CIPChangeNotifier *MyIPChanger;
void SDT_ReloadChannels(); void SDT_ReloadChannels();
void firstChannel();
void setupNetwork( bool force= false ); void setupNetwork( bool force= false );
void setupNFS(); void setupNFS();