mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-31 17:31:20 +02:00
nhttpd: fix switch tv<>radio in standby mode
This commit is contained in:
@@ -332,17 +332,27 @@ void CControlAPI::SetModeCGI(CyhookHandler *hh)
|
|||||||
|
|
||||||
if (hh->ParamList["1"] == "radio") // switch to radio mode
|
if (hh->ParamList["1"] == "radio") // switch to radio mode
|
||||||
{
|
{
|
||||||
int mode = NeutrinoMessages::mode_radio;
|
if(CNeutrinoApp::getInstance()->getMode() != NeutrinoMessages::mode_standby){
|
||||||
NeutrinoAPI->EventServer->sendEvent(NeutrinoMessages::CHANGEMODE, CEventServer::INITID_HTTPD, (void *)&mode,sizeof(int));
|
int mode = NeutrinoMessages::mode_radio;
|
||||||
sleep(1);
|
NeutrinoAPI->EventServer->sendEvent(NeutrinoMessages::CHANGEMODE, CEventServer::INITID_HTTPD, (void *)&mode,sizeof(int));
|
||||||
NeutrinoAPI->UpdateBouquets();
|
sleep(1);
|
||||||
|
NeutrinoAPI->UpdateBouquets();
|
||||||
|
}else{
|
||||||
|
extern CRemoteControl * g_RemoteControl;
|
||||||
|
g_RemoteControl->radioMode();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (hh->ParamList["1"] == "tv") // switch to tv mode
|
else if (hh->ParamList["1"] == "tv") // switch to tv mode
|
||||||
{
|
{
|
||||||
int mode = NeutrinoMessages::mode_tv;
|
if(CNeutrinoApp::getInstance()->getMode() != NeutrinoMessages::mode_standby){
|
||||||
NeutrinoAPI->EventServer->sendEvent(NeutrinoMessages::CHANGEMODE, CEventServer::INITID_HTTPD, (void *)&mode,sizeof(int));
|
int mode = NeutrinoMessages::mode_tv;
|
||||||
sleep(1);
|
NeutrinoAPI->EventServer->sendEvent(NeutrinoMessages::CHANGEMODE, CEventServer::INITID_HTTPD, (void *)&mode,sizeof(int));
|
||||||
NeutrinoAPI->UpdateBouquets();
|
sleep(1);
|
||||||
|
NeutrinoAPI->UpdateBouquets();
|
||||||
|
}else{
|
||||||
|
extern CRemoteControl * g_RemoteControl;
|
||||||
|
g_RemoteControl->tvMode();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (hh->ParamList["record"] == "start") // start record mode
|
else if (hh->ParamList["record"] == "start") // start record mode
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user