From 4f749743d0c16fbbdf91fd1ffb1d28e9e96d3078 Mon Sep 17 00:00:00 2001 From: satbaby Date: Thu, 16 Feb 2012 16:06:44 +0000 Subject: [PATCH] -add user defined key for Current Transponder List git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-beta@2110 e54a6e83-5905-42d5-8d5c-058d10e6a962 --- data/locale/deutsch.locale | 1 + data/locale/english.locale | 1 + src/gui/keybind_setup.cpp | 5 +++-- src/gui/keybind_setup.h | 1 + src/neutrino.cpp | 6 ++++-- src/system/locals.h | 1 + src/system/locals_intern.h | 1 + src/system/settings.h | 2 ++ 8 files changed, 14 insertions(+), 4 deletions(-) diff --git a/data/locale/deutsch.locale b/data/locale/deutsch.locale index f4eeca262..c7d67db56 100644 --- a/data/locale/deutsch.locale +++ b/data/locale/deutsch.locale @@ -332,6 +332,7 @@ extra.fec_s2_qpsk_5_6 5/6 S2_QPSK extra.fec_s2_qpsk_7_8 7/8 S2_QPSK extra.fec_s2_qpsk_8_9 8/9 S2_QPSK extra.fec_s2_qpsk_9_10 9/10 S2_QPSK +extra.key_current_transponder Aktuelle Transponder Taste extra.key_list_end Listenende extra.key_list_start Listenanfang extra.key_plugin One-touch-Plugin diff --git a/data/locale/english.locale b/data/locale/english.locale index d2b65b75d..47590a50e 100644 --- a/data/locale/english.locale +++ b/data/locale/english.locale @@ -332,6 +332,7 @@ extra.fec_s2_qpsk_5_6 5/6 s2 qpsk extra.fec_s2_qpsk_7_8 7/8 s2 qpsk extra.fec_s2_qpsk_8_9 8/9 s2 qpsk extra.fec_s2_qpsk_9_10 9/10 s2 qpsk +extra.key_current_transponder Current Transponder Key extra.key_list_end end extra.key_list_start home extra.key_plugin One touch plugin diff --git a/src/gui/keybind_setup.cpp b/src/gui/keybind_setup.cpp index abb70d9b9..98f871f0d 100644 --- a/src/gui/keybind_setup.cpp +++ b/src/gui/keybind_setup.cpp @@ -175,6 +175,7 @@ const key_settings_struct_t key_settings[CKeybindSetup::KEYBINDS_COUNT] = {LOCALE_KEYBINDINGMENU_ADDREMIND, &g_settings.key_channelList_addremind, }, {LOCALE_KEYBINDINGMENU_BOUQUETUP, &g_settings.key_bouquet_up, }, {LOCALE_KEYBINDINGMENU_BOUQUETDOWN, &g_settings.key_bouquet_down, }, + {LOCALE_EXTRA_KEY_CURRENT_TRANSPONDER, &g_settings.key_current_transponder, }, {LOCALE_KEYBINDINGMENU_CHANNELUP, &g_settings.key_quickzap_up, }, {LOCALE_KEYBINDINGMENU_CHANNELDOWN, &g_settings.key_quickzap_down, }, {LOCALE_KEYBINDINGMENU_SUBCHANNELUP, &g_settings.key_subchannel_up, }, @@ -193,7 +194,7 @@ const key_settings_struct_t key_settings[CKeybindSetup::KEYBINDS_COUNT] = {LOCALE_MPKEY_PLUGIN, &g_settings.mpkey_plugin, }, {LOCALE_EXTRA_KEY_PLUGIN, &g_settings.key_plugin, }, {LOCALE_EXTRA_KEY_UNLOCK, &g_settings.key_unlock, }, - {LOCALE_EXTRA_KEY_SCREENSHOT, &g_settings.key_screenshot, }, + {LOCALE_EXTRA_KEY_SCREENSHOT, &g_settings.key_screenshot, } }; @@ -311,7 +312,7 @@ void CKeybindSetup::showKeyBindChannellistSetup(CMenuWidget *bindSettings_chlist CMenuOptionChooser *oj = new CMenuOptionChooser(LOCALE_KEYBINDINGMENU_BOUQUETHANDLING, &g_settings.bouquetlist_mode, KEYBINDINGMENU_BOUQUETHANDLING_OPTIONS, KEYBINDINGMENU_BOUQUETHANDLING_OPTION_COUNT, true ); bindSettings_chlist->addItem(oj); - for (int i = KEY_PAGE_UP; i <= KEY_BOUQUET_DOWN; i++) + for (int i = KEY_PAGE_UP; i <= KEY_CURRENT_TRANSPONDER; i++) bindSettings_chlist->addItem(new CMenuForwarder(key_settings[i].keydescription, true, keychooser[i]->getKeyName(), keychooser[i])); bindSettings_chlist->addItem(new CMenuOptionChooser(LOCALE_EXTRA_SMS_CHANNEL, &g_settings.sms_channel, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true)); diff --git a/src/gui/keybind_setup.h b/src/gui/keybind_setup.h index 16854b7af..7f0a1b223 100644 --- a/src/gui/keybind_setup.h +++ b/src/gui/keybind_setup.h @@ -56,6 +56,7 @@ class CKeybindSetup : public CMenuTarget KEY_ADD_REMIND, KEY_BOUQUET_UP, KEY_BOUQUET_DOWN, + KEY_CURRENT_TRANSPONDER, KEY_CHANNEL_UP, KEY_CHANNEL_DOWN, KEY_SUBCHANNEL_UP, diff --git a/src/neutrino.cpp b/src/neutrino.cpp index 144f5079c..09097f2d9 100644 --- a/src/neutrino.cpp +++ b/src/neutrino.cpp @@ -2075,7 +2075,7 @@ void CNeutrinoApp::RealRun(CMenuWidget &mainMenu) else if(msg == (neutrino_msg_t) g_settings.key_timeshift) { CRecordManager::getInstance()->StartTimeshift(); } - else if (msg == CRCInput::RC_games){ + else if (msg == (neutrino_msg_t) g_settings.key_current_transponder){ StopSubtitles(); int res = channelList->numericZap( msg ); StartSubtitles(res < 0); @@ -3780,6 +3780,7 @@ void CNeutrinoApp::loadKeys(const char * fname) g_settings.key_plugin = configfile.getInt32( "key_plugin", CRCInput::RC_nokey ); g_settings.key_unlock = configfile.getInt32( "key_unlock", CRCInput::RC_setup ); g_settings.key_screenshot = configfile.getInt32( "key_screenshot", CRCInput::RC_nokey ); + g_settings.key_current_transponder = configfile.getInt32( "key_current_transponder", CRCInput::RC_nokey ); g_settings.key_quickzap_up = tconfig.getInt32( "key_quickzap_up", CRCInput::RC_up ); g_settings.key_quickzap_down = tconfig.getInt32( "key_quickzap_down", CRCInput::RC_down ); @@ -3833,6 +3834,7 @@ void CNeutrinoApp::saveKeys(const char * fname) tconfig.setInt32( "key_plugin", g_settings.key_plugin ); tconfig.setInt32( "key_unlock", g_settings.key_unlock ); tconfig.setInt32( "key_screenshot", g_settings.key_screenshot ); + tconfig.setInt32( "key_current_transponder", g_settings.key_current_transponder ); tconfig.setInt32( "key_quickzap_up", g_settings.key_quickzap_up ); tconfig.setInt32( "key_quickzap_down", g_settings.key_quickzap_down ); @@ -3948,4 +3950,4 @@ void CNeutrinoApp::SDT_ReloadChannels() g_RCInput->postMsg(CRCInput::RC_ok, 0); } -} +} \ No newline at end of file diff --git a/src/system/locals.h b/src/system/locals.h index 61b0e5a67..24771bfa0 100644 --- a/src/system/locals.h +++ b/src/system/locals.h @@ -359,6 +359,7 @@ typedef enum LOCALE_EXTRA_FEC_S2_QPSK_7_8, LOCALE_EXTRA_FEC_S2_QPSK_8_9, LOCALE_EXTRA_FEC_S2_QPSK_9_10, + LOCALE_EXTRA_KEY_CURRENT_TRANSPONDER, LOCALE_EXTRA_KEY_LIST_END, LOCALE_EXTRA_KEY_LIST_START, LOCALE_EXTRA_KEY_PLUGIN, diff --git a/src/system/locals_intern.h b/src/system/locals_intern.h index f10851668..de81b341f 100644 --- a/src/system/locals_intern.h +++ b/src/system/locals_intern.h @@ -359,6 +359,7 @@ const char * locale_real_names[] = "extra.fec_s2_qpsk_7_8", "extra.fec_s2_qpsk_8_9", "extra.fec_s2_qpsk_9_10", + "extra.key_current_transponder", "extra.key_list_end", "extra.key_list_start", "extra.key_plugin", diff --git a/src/system/settings.h b/src/system/settings.h index e120c02d8..3eee23630 100644 --- a/src/system/settings.h +++ b/src/system/settings.h @@ -375,6 +375,8 @@ struct SNeutrinoSettings int screenshot_count; int screenshot_format; + int key_current_transponder; + int cacheTXT; int minimode; int mode_clock;