From e5dcd5a4ffa576b227f9ed49303525b434aa1fe4 Mon Sep 17 00:00:00 2001 From: svenhoefer Date: Sun, 29 Jul 2018 01:11:33 +0200 Subject: [PATCH] - record-menu: allow to exit with RC_stop, when no records available This allows to call and exit this menu without to move the finger on the remotecontrol Signed-off-by: Thilo Graf --- src/driver/record.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/driver/record.cpp b/src/driver/record.cpp index 04960ab89..05dd1b03d 100644 --- a/src/driver/record.cpp +++ b/src/driver/record.cpp @@ -1464,6 +1464,9 @@ int CRecordManager::exec(CMenuTarget* parent, const std::string & actionKey ) ShowHint(LOCALE_MAINMENU_RECORDING_STOP, g_Locale->getText(LOCALE_RECORDINGMENU_RECORD_IS_NOT_RUNNING), 450, 2); return menu_return::RETURN_EXIT_ALL; } + } else if (actionKey == "Exit") + { + return menu_return::RETURN_EXIT_ALL; } ShowMenu(); @@ -1483,6 +1486,8 @@ bool CRecordManager::ShowMenu(void) CMenuSelectorTarget * selector = new CMenuSelectorTarget(&select); CMenuWidget menu(LOCALE_MAINMENU_RECORDING, NEUTRINO_ICON_RECORDING /*, width*/); + if (rec_count == 0) + menu.addKey(CRCInput::RC_stop, this, "Exit"); menu.addIntroItems(NONEXISTANT_LOCALE, NONEXISTANT_LOCALE, CMenuWidget::BTN_TYPE_CANCEL); // Record / Timeshift