diff --git a/src/gui/audioplayer.cpp b/src/gui/audioplayer.cpp index 3227be9b4..23d8bdc3a 100644 --- a/src/gui/audioplayer.cpp +++ b/src/gui/audioplayer.cpp @@ -819,6 +819,7 @@ int CAudioPlayerGui::show() else if (msg == NeutrinoMessages::RECORD_START || msg == NeutrinoMessages::ZAPTO || msg == NeutrinoMessages::STANDBY_ON || + msg == NeutrinoMessages::LEAVE_ALL || msg == NeutrinoMessages::SHUTDOWN || ((msg == NeutrinoMessages::SLEEPTIMER) && !data)) { diff --git a/src/gui/filebrowser.cpp b/src/gui/filebrowser.cpp index 1829e30b6..fa2485457 100644 --- a/src/gui/filebrowser.cpp +++ b/src/gui/filebrowser.cpp @@ -678,6 +678,7 @@ bool CFileBrowser::exec(const char * const dirname) } } else if (msg == NeutrinoMessages::STANDBY_ON || + msg == NeutrinoMessages::LEAVE_ALL || msg == NeutrinoMessages::SHUTDOWN || msg == NeutrinoMessages::SLEEPTIMER) { @@ -957,6 +958,7 @@ bool CFileBrowser::playlist_manager(CFileList &playlist, unsigned int playing) loop = false; } else if (msg == NeutrinoMessages::STANDBY_ON || + msg == NeutrinoMessages::LEAVE_ALL || msg == NeutrinoMessages::SHUTDOWN || msg == NeutrinoMessages::SLEEPTIMER) { diff --git a/src/gui/moviebrowser.cpp b/src/gui/moviebrowser.cpp index 82c02eee2..7136c71eb 100644 --- a/src/gui/moviebrowser.cpp +++ b/src/gui/moviebrowser.cpp @@ -1091,6 +1091,7 @@ int CMovieBrowser::exec(const char* path) //FIXME do nothing ? } else if (msg == NeutrinoMessages::STANDBY_ON || + msg == NeutrinoMessages::LEAVE_ALL || msg == NeutrinoMessages::SHUTDOWN || msg == NeutrinoMessages::SLEEPTIMER) { diff --git a/src/gui/movieplayer.cpp b/src/gui/movieplayer.cpp index 7c7995cab..0fea9a14b 100644 --- a/src/gui/movieplayer.cpp +++ b/src/gui/movieplayer.cpp @@ -1163,6 +1163,7 @@ void CMoviePlayerGui::PlayFileLoop(void) CNeutrinoApp::getInstance()->handleMsg(msg, data); } else if (msg == NeutrinoMessages::ZAPTO || msg == NeutrinoMessages::STANDBY_ON || + msg == NeutrinoMessages::LEAVE_ALL || msg == NeutrinoMessages::SHUTDOWN || ((msg == NeutrinoMessages::SLEEPTIMER) && !data) ) { // Exit for Record/Zapto Timers printf("CMoviePlayerGui::PlayFile: ZAPTO etc..\n"); diff --git a/src/gui/pictureviewer.cpp b/src/gui/pictureviewer.cpp index 3b98f59ad..07c8d979e 100644 --- a/src/gui/pictureviewer.cpp +++ b/src/gui/pictureviewer.cpp @@ -621,6 +621,7 @@ int CPictureViewerGui::show() else if (msg == NeutrinoMessages::RECORD_START || msg == NeutrinoMessages::ZAPTO || msg == NeutrinoMessages::STANDBY_ON || + msg == NeutrinoMessages::LEAVE_ALL || msg == NeutrinoMessages::SHUTDOWN || msg == NeutrinoMessages::SLEEPTIMER) { diff --git a/src/gui/upnpbrowser.cpp b/src/gui/upnpbrowser.cpp index d38eb3b78..d7cc5de49 100644 --- a/src/gui/upnpbrowser.cpp +++ b/src/gui/upnpbrowser.cpp @@ -530,6 +530,7 @@ void CUpnpBrowserGui::selectDevice() else if (msg == NeutrinoMessages::RECORD_START || msg == NeutrinoMessages::ZAPTO || msg == NeutrinoMessages::STANDBY_ON || + msg == NeutrinoMessages::LEAVE_ALL || msg == NeutrinoMessages::SHUTDOWN || msg == NeutrinoMessages::SLEEPTIMER) { @@ -841,6 +842,7 @@ bool CUpnpBrowserGui::selectItem(std::string id) else if (msg == NeutrinoMessages::RECORD_START || msg == NeutrinoMessages::ZAPTO || msg == NeutrinoMessages::STANDBY_ON || + msg == NeutrinoMessages::LEAVE_ALL || msg == NeutrinoMessages::SHUTDOWN || msg == NeutrinoMessages::SLEEPTIMER) { diff --git a/src/neutrino.cpp b/src/neutrino.cpp index bb52830eb..5c1b16d2e 100644 --- a/src/neutrino.cpp +++ b/src/neutrino.cpp @@ -2795,6 +2795,11 @@ int CNeutrinoApp::handleMsg(const neutrino_msg_t _msg, neutrino_msg_data_t data) g_RCInput->postMsg(NeutrinoMessages::SHUTDOWN, 0); return messages_return::cancel_all | messages_return::handled; } + else if ((msg == CRCInput::RC_tv) || (msg == CRCInput::RC_radio)) { + if (data == 0) + g_RCInput->postMsg(NeutrinoMessages::LEAVE_ALL, 0); + return messages_return::cancel_all | messages_return::handled; + } else if (msg == (neutrino_msg_t) g_settings.key_power_off /*CRCInput::RC_standby*/) { if (data == 0) { neutrino_msg_t new_msg; @@ -3153,6 +3158,10 @@ int CNeutrinoApp::handleMsg(const neutrino_msg_t _msg, neutrino_msg_data_t data) g_RCInput->clearRCMsg(); return messages_return::handled; } + else if( msg == NeutrinoMessages::LEAVE_ALL ) { + g_RCInput->clearRCMsg(); + return messages_return::handled; + } else if( msg == NeutrinoMessages::STANDBY_ON ) { if( mode != mode_standby ) { standbyMode( true ); diff --git a/src/neutrinoMessages.h b/src/neutrinoMessages.h index 2de01b397..65519c02f 100644 --- a/src/neutrinoMessages.h +++ b/src/neutrinoMessages.h @@ -74,6 +74,7 @@ struct NeutrinoMessages { REBOOT = CRCInput::RC_Messages + 21, RELOAD_SETUP = CRCInput::RC_Messages + 22, SHOW_MAINMENU = CRCInput::RC_Messages + 23, + LEAVE_ALL = CRCInput::RC_Messages + 24, EVT_VOLCHANGED = CRCInput::RC_Events + 1, EVT_MUTECHANGED = CRCInput::RC_Events + 2,