diff --git a/src/gui/audio_select.cpp b/src/gui/audio_select.cpp index 73c693f3a..6dde054fa 100644 --- a/src/gui/audio_select.cpp +++ b/src/gui/audio_select.cpp @@ -56,9 +56,9 @@ int dvbsub_getpid(); #define AUDIOMENU_ANALOGOUT_OPTION_COUNT 3 const CMenuOptionChooser::keyval AUDIOMENU_ANALOGOUT_OPTIONS[AUDIOMENU_ANALOGOUT_OPTION_COUNT] = { - { 0, LOCALE_AUDIOMENU_STEREO ,0 }, - { 1, LOCALE_AUDIOMENU_MONOLEFT ,0 }, - { 2, LOCALE_AUDIOMENU_MONORIGHT ,0} + { 0, LOCALE_AUDIOMENU_STEREO }, + { 1, LOCALE_AUDIOMENU_MONOLEFT }, + { 2, LOCALE_AUDIOMENU_MONORIGHT } }; int CAudioSelectMenuHandler::exec(CMenuTarget* parent, const std::string &/*actionkey*/) diff --git a/src/gui/epgplus.cpp b/src/gui/epgplus.cpp index 54211808e..8dc90aa5f 100644 --- a/src/gui/epgplus.cpp +++ b/src/gui/epgplus.cpp @@ -1241,8 +1241,8 @@ int EpgPlus::MenuTargetRefreshEpg::exec (CMenuTarget * /*parent*/, const std::st } struct CMenuOptionChooser::keyval menuOptionChooserSwitchSwapModes[] = { - {EpgPlus::SwapMode_ByPage, LOCALE_EPGPLUS_BYPAGE_MODE,0}, - {EpgPlus::SwapMode_ByBouquet, LOCALE_EPGPLUS_BYBOUQUET_MODE,0} + { EpgPlus::SwapMode_ByPage, LOCALE_EPGPLUS_BYPAGE_MODE }, + { EpgPlus::SwapMode_ByBouquet, LOCALE_EPGPLUS_BYBOUQUET_MODE } }; EpgPlus::MenuOptionChooserSwitchSwapMode::MenuOptionChooserSwitchSwapMode (EpgPlus * pepgPlus) @@ -1284,8 +1284,8 @@ int EpgPlus::MenuOptionChooserSwitchSwapMode::exec (CMenuTarget * parent) } struct CMenuOptionChooser::keyval menuOptionChooserSwitchViewModes[] = { - {EpgPlus::ViewMode_Scroll, LOCALE_EPGPLUS_STRETCH_MODE,0}, - {EpgPlus::ViewMode_Stretch, LOCALE_EPGPLUS_SCROLL_MODE,0} + { EpgPlus::ViewMode_Scroll, LOCALE_EPGPLUS_STRETCH_MODE }, + { EpgPlus::ViewMode_Stretch, LOCALE_EPGPLUS_SCROLL_MODE } }; EpgPlus::MenuOptionChooserSwitchViewMode::MenuOptionChooserSwitchViewMode (EpgPlus * epgPlus) diff --git a/src/gui/eventlist.cpp b/src/gui/eventlist.cpp index 8950986fa..c24b9887b 100644 --- a/src/gui/eventlist.cpp +++ b/src/gui/eventlist.cpp @@ -912,21 +912,21 @@ bool CEventFinderMenuHandler::changeNotify(const neutrino_locale_t OptionName, v #define SEARCH_LIST_OPTION_COUNT 3 const CMenuOptionChooser::keyval SEARCH_LIST_OPTIONS[SEARCH_LIST_OPTION_COUNT] = { -// { EventList::SEARCH_LIST_NONE , LOCALE_PICTUREVIEWER_RESIZE_NONE ,0 }, - { EventList::SEARCH_LIST_CHANNEL , LOCALE_TIMERLIST_CHANNEL ,0 }, - { EventList::SEARCH_LIST_BOUQUET , LOCALE_BOUQUETLIST_HEAD ,0 }, - { EventList::SEARCH_LIST_ALL , LOCALE_CHANNELLIST_HEAD ,0 } +// { EventList::SEARCH_LIST_NONE, LOCALE_PICTUREVIEWER_RESIZE_NONE }, + { EventList::SEARCH_LIST_CHANNEL, LOCALE_TIMERLIST_CHANNEL }, + { EventList::SEARCH_LIST_BOUQUET, LOCALE_BOUQUETLIST_HEAD }, + { EventList::SEARCH_LIST_ALL, LOCALE_CHANNELLIST_HEAD } }; #define SEARCH_EPG_OPTION_COUNT 3 const CMenuOptionChooser::keyval SEARCH_EPG_OPTIONS[SEARCH_EPG_OPTION_COUNT] = { -// { EventList::SEARCH_EPG_NONE , LOCALE_PICTUREVIEWER_RESIZE_NONE ,0 }, - { EventList::SEARCH_EPG_TITLE , LOCALE_FONTSIZE_EPG_TITLE ,0}, - { EventList::SEARCH_EPG_INFO1 , LOCALE_FONTSIZE_EPG_INFO1 ,0 }, - { EventList::SEARCH_EPG_INFO2 , LOCALE_FONTSIZE_EPG_INFO2 ,0 } -// ,{ EventList::SEARCH_EPG_GENRE , LOCALE_MOVIEBROWSER_INFO_GENRE_MAJOR } +// { EventList::SEARCH_EPG_NONE, LOCALE_PICTUREVIEWER_RESIZE_NONE }, + { EventList::SEARCH_EPG_TITLE, LOCALE_FONTSIZE_EPG_TITLE }, + { EventList::SEARCH_EPG_INFO1, LOCALE_FONTSIZE_EPG_INFO1 }, + { EventList::SEARCH_EPG_INFO2, LOCALE_FONTSIZE_EPG_INFO2 } +// ,{ EventList::SEARCH_EPG_GENRE, LOCALE_MOVIEBROWSER_INFO_GENRE_MAJOR } }; diff --git a/src/gui/moviebrowser.cpp b/src/gui/moviebrowser.cpp index af17bd8c1..deeab59ed 100644 --- a/src/gui/moviebrowser.cpp +++ b/src/gui/moviebrowser.cpp @@ -96,52 +96,52 @@ void strReplace(std::string& orig, const char* fstr, const std::string rstr); #define MESSAGEBOX_BROWSER_ROW_ITEM_COUNT 20 const CMenuOptionChooser::keyval MESSAGEBOX_BROWSER_ROW_ITEM[MESSAGEBOX_BROWSER_ROW_ITEM_COUNT] = { - { MB_INFO_FILENAME, LOCALE_MOVIEBROWSER_INFO_FILENAME ,0 }, - { MB_INFO_FILEPATH, LOCALE_MOVIEBROWSER_INFO_PATH ,0 }, - { MB_INFO_TITLE, LOCALE_MOVIEBROWSER_INFO_TITLE ,0 }, - { MB_INFO_SERIE, LOCALE_MOVIEBROWSER_INFO_SERIE ,0 }, - { MB_INFO_INFO1, LOCALE_MOVIEBROWSER_INFO_INFO1 ,0 }, - { MB_INFO_MAJOR_GENRE, LOCALE_MOVIEBROWSER_INFO_GENRE_MAJOR ,0 }, - { MB_INFO_MINOR_GENRE, LOCALE_MOVIEBROWSER_INFO_GENRE_MINOR ,0 }, - { MB_INFO_PARENTAL_LOCKAGE, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE ,0 }, - { MB_INFO_CHANNEL, LOCALE_MOVIEBROWSER_INFO_CHANNEL ,0 }, - { MB_INFO_QUALITY, LOCALE_MOVIEBROWSER_INFO_QUALITY ,0 }, - { MB_INFO_PREVPLAYDATE, LOCALE_MOVIEBROWSER_INFO_PREVPLAYDATE ,0 }, - { MB_INFO_RECORDDATE, LOCALE_MOVIEBROWSER_INFO_RECORDDATE ,0 }, - { MB_INFO_PRODDATE, LOCALE_MOVIEBROWSER_INFO_PRODYEAR ,0 }, - { MB_INFO_COUNTRY, LOCALE_MOVIEBROWSER_INFO_PRODCOUNTRY ,0 }, - { MB_INFO_GEOMETRIE, LOCALE_MOVIEBROWSER_INFO_VIDEOFORMAT ,0 }, - { MB_INFO_AUDIO, LOCALE_MOVIEBROWSER_INFO_AUDIO ,0 }, - { MB_INFO_LENGTH, LOCALE_MOVIEBROWSER_INFO_LENGTH ,0 }, - { MB_INFO_SIZE, LOCALE_MOVIEBROWSER_INFO_SIZE ,0 }, - { MB_INFO_BOOKMARK, LOCALE_MOVIEBROWSER_MENU_MAIN_BOOKMARKS ,0 }, - { MB_INFO_FILENAME, LOCALE_MOVIEBROWSER_INFO_FILENAME ,0 } - }; + { MB_INFO_FILENAME, LOCALE_MOVIEBROWSER_INFO_FILENAME }, + { MB_INFO_FILEPATH, LOCALE_MOVIEBROWSER_INFO_PATH }, + { MB_INFO_TITLE, LOCALE_MOVIEBROWSER_INFO_TITLE }, + { MB_INFO_SERIE, LOCALE_MOVIEBROWSER_INFO_SERIE }, + { MB_INFO_INFO1, LOCALE_MOVIEBROWSER_INFO_INFO1 }, + { MB_INFO_MAJOR_GENRE, LOCALE_MOVIEBROWSER_INFO_GENRE_MAJOR }, + { MB_INFO_MINOR_GENRE, LOCALE_MOVIEBROWSER_INFO_GENRE_MINOR }, + { MB_INFO_PARENTAL_LOCKAGE, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE }, + { MB_INFO_CHANNEL, LOCALE_MOVIEBROWSER_INFO_CHANNEL }, + { MB_INFO_QUALITY, LOCALE_MOVIEBROWSER_INFO_QUALITY }, + { MB_INFO_PREVPLAYDATE, LOCALE_MOVIEBROWSER_INFO_PREVPLAYDATE }, + { MB_INFO_RECORDDATE, LOCALE_MOVIEBROWSER_INFO_RECORDDATE }, + { MB_INFO_PRODDATE, LOCALE_MOVIEBROWSER_INFO_PRODYEAR }, + { MB_INFO_COUNTRY, LOCALE_MOVIEBROWSER_INFO_PRODCOUNTRY }, + { MB_INFO_GEOMETRIE, LOCALE_MOVIEBROWSER_INFO_VIDEOFORMAT }, + { MB_INFO_AUDIO, LOCALE_MOVIEBROWSER_INFO_AUDIO }, + { MB_INFO_LENGTH, LOCALE_MOVIEBROWSER_INFO_LENGTH }, + { MB_INFO_SIZE, LOCALE_MOVIEBROWSER_INFO_SIZE }, + { MB_INFO_BOOKMARK, LOCALE_MOVIEBROWSER_MENU_MAIN_BOOKMARKS }, + { MB_INFO_FILENAME, LOCALE_MOVIEBROWSER_INFO_FILENAME } +}; #define MESSAGEBOX_YES_NO_OPTIONS_COUNT 2 const CMenuOptionChooser::keyval MESSAGEBOX_YES_NO_OPTIONS[MESSAGEBOX_YES_NO_OPTIONS_COUNT] = { - { 0, LOCALE_MESSAGEBOX_NO ,0 }, - { 1, LOCALE_MESSAGEBOX_YES ,0 } + { 0, LOCALE_MESSAGEBOX_NO }, + { 1, LOCALE_MESSAGEBOX_YES } }; #define MESSAGEBOX_PARENTAL_LOCK_OPTIONS_COUNT 3 const CMenuOptionChooser::keyval MESSAGEBOX_PARENTAL_LOCK_OPTIONS[MESSAGEBOX_PARENTAL_LOCK_OPTIONS_COUNT] = { - { 1, LOCALE_MOVIEBROWSER_MENU_PARENTAL_LOCK_ACTIVATED_YES ,0 }, - { 0, LOCALE_MOVIEBROWSER_MENU_PARENTAL_LOCK_ACTIVATED_NO ,0 }, - { 2, LOCALE_MOVIEBROWSER_MENU_PARENTAL_LOCK_ACTIVATED_NO_TEMP ,0 } + { 1, LOCALE_MOVIEBROWSER_MENU_PARENTAL_LOCK_ACTIVATED_YES }, + { 0, LOCALE_MOVIEBROWSER_MENU_PARENTAL_LOCK_ACTIVATED_NO }, + { 2, LOCALE_MOVIEBROWSER_MENU_PARENTAL_LOCK_ACTIVATED_NO_TEMP } }; #define MESSAGEBOX_PARENTAL_LOCKAGE_OPTION_COUNT 6 const CMenuOptionChooser::keyval MESSAGEBOX_PARENTAL_LOCKAGE_OPTIONS[MESSAGEBOX_PARENTAL_LOCKAGE_OPTION_COUNT] = { - { 0, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE_0YEAR ,0}, - { 6, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE_6YEAR,0 }, - { 12, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE_12YEAR ,0}, - { 16, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE_16YEAR ,0}, - { 18, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE_18YEAR,0 }, - { 99, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE_ALWAYS ,0} + { 0, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE_0YEAR }, + { 6, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE_6YEAR }, + { 12, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE_12YEAR }, + { 16, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE_16YEAR }, + { 18, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE_18YEAR }, + { 99, LOCALE_MOVIEBROWSER_INFO_PARENTAL_LOCKAGE_ALWAYS } }; #define MAX_WINDOW_WIDTH (g_settings.screen_EndX - g_settings.screen_StartX - 40) diff --git a/src/gui/moviebrowser.h b/src/gui/moviebrowser.h index e5cfab652..5b60f05e0 100644 --- a/src/gui/moviebrowser.h +++ b/src/gui/moviebrowser.h @@ -492,213 +492,213 @@ class CDirMenu : public CMenuWidget #define GENRE_ALL_COUNT 76 const CMenuOptionChooser::keyval GENRE_ALL[GENRE_ALL_COUNT] = { - { 0x00, LOCALE_GENRE_UNKNOWN,0 }, - { 0x10, LOCALE_GENRE_MOVIE_0,0 }, - { 0x11, LOCALE_GENRE_MOVIE_1,0 }, - { 0x12, LOCALE_GENRE_MOVIE_2,0 }, - { 0x13, LOCALE_GENRE_MOVIE_3,0 }, - { 0x14, LOCALE_GENRE_MOVIE_4,0 }, - { 0x15, LOCALE_GENRE_MOVIE_5,0 }, - { 0x16, LOCALE_GENRE_MOVIE_6,0 }, - { 0x17, LOCALE_GENRE_MOVIE_7,0 }, - { 0x18, LOCALE_GENRE_MOVIE_8,0 }, - { 0x20, LOCALE_GENRE_NEWS_0,0 }, - { 0x21, LOCALE_GENRE_NEWS_1,0 }, - { 0x22, LOCALE_GENRE_NEWS_2,0 }, - { 0x23, LOCALE_GENRE_NEWS_3,0 }, - { 0x24, LOCALE_GENRE_NEWS_4,0 }, - { 0x30, LOCALE_GENRE_SHOW_0,0 }, - { 0x31, LOCALE_GENRE_SHOW_1,0 }, - { 0x32, LOCALE_GENRE_SHOW_2,0 }, - { 0x33, LOCALE_GENRE_SHOW_3,0 }, - { 0x40, LOCALE_GENRE_SPORTS_0,0 }, - { 0x41, LOCALE_GENRE_SPORTS_1,0 }, - { 0x42, LOCALE_GENRE_SPORTS_2,0 }, - { 0x43, LOCALE_GENRE_SPORTS_3,0 }, - { 0x44, LOCALE_GENRE_SPORTS_4,0 }, - { 0x45, LOCALE_GENRE_SPORTS_5,0 }, - { 0x46, LOCALE_GENRE_SPORTS_6,0 }, - { 0x47, LOCALE_GENRE_SPORTS_7,0 }, - { 0x48, LOCALE_GENRE_SPORTS_8,0 }, - { 0x49, LOCALE_GENRE_SPORTS_9,0 }, - { 0x4A, LOCALE_GENRE_SPORTS_10,0 }, - { 0x4B, LOCALE_GENRE_SPORTS_11,0 }, - { 0x50, LOCALE_GENRE_CHILDRENS_PROGRAMMES_0,0 }, - { 0x51, LOCALE_GENRE_CHILDRENS_PROGRAMMES_1,0 }, - { 0x52, LOCALE_GENRE_CHILDRENS_PROGRAMMES_2,0 }, - { 0x53, LOCALE_GENRE_CHILDRENS_PROGRAMMES_3,0 }, - { 0x54, LOCALE_GENRE_CHILDRENS_PROGRAMMES_4,0 }, - { 0x55, LOCALE_GENRE_CHILDRENS_PROGRAMMES_5,0 }, - { 0x60, LOCALE_GENRE_MUSIC_DANCE_0,0 }, - { 0x61, LOCALE_GENRE_MUSIC_DANCE_1,0 }, - { 0x62, LOCALE_GENRE_MUSIC_DANCE_2,0 }, - { 0x63, LOCALE_GENRE_MUSIC_DANCE_3,0 }, - { 0x64, LOCALE_GENRE_MUSIC_DANCE_4,0 }, - { 0x65, LOCALE_GENRE_MUSIC_DANCE_5,0 }, - { 0x66, LOCALE_GENRE_MUSIC_DANCE_6,0 }, - { 0x70, LOCALE_GENRE_ARTS_0,0 }, - { 0x71, LOCALE_GENRE_ARTS_1,0 }, - { 0x72, LOCALE_GENRE_ARTS_2,0 }, - { 0x73, LOCALE_GENRE_ARTS_3,0 }, - { 0x74, LOCALE_GENRE_ARTS_4,0 }, - { 0x75, LOCALE_GENRE_ARTS_5,0 }, - { 0x76, LOCALE_GENRE_ARTS_6,0 }, - { 0x77, LOCALE_GENRE_ARTS_7,0 }, - { 0x78, LOCALE_GENRE_ARTS_8,0 }, - { 0x79, LOCALE_GENRE_ARTS_9,0 }, - { 0x7A, LOCALE_GENRE_ARTS_10,0 }, - { 0x7B, LOCALE_GENRE_ARTS_11,0 }, - { 0x80, LOCALE_GENRE_SOCIAL_POLITICAL_0,0 }, - { 0x81, LOCALE_GENRE_SOCIAL_POLITICAL_1,0 }, - { 0x82, LOCALE_GENRE_SOCIAL_POLITICAL_2,0 }, - { 0x83, LOCALE_GENRE_SOCIAL_POLITICAL_3,0 }, - { 0x90, LOCALE_GENRE_DOCUS_MAGAZINES_0,0 }, - { 0x91, LOCALE_GENRE_DOCUS_MAGAZINES_1,0 }, - { 0x92, LOCALE_GENRE_DOCUS_MAGAZINES_2,0 }, - { 0x93, LOCALE_GENRE_DOCUS_MAGAZINES_3,0 }, - { 0x94, LOCALE_GENRE_DOCUS_MAGAZINES_4,0 }, - { 0x95, LOCALE_GENRE_DOCUS_MAGAZINES_5,0 }, - { 0x96, LOCALE_GENRE_DOCUS_MAGAZINES_6,0 }, - { 0x97, LOCALE_GENRE_DOCUS_MAGAZINES_7,0 }, - { 0xA0, LOCALE_GENRE_TRAVEL_HOBBIES_0,0 }, - { 0xA1, LOCALE_GENRE_TRAVEL_HOBBIES_1,0 }, - { 0xA2, LOCALE_GENRE_TRAVEL_HOBBIES_2,0 }, - { 0xA3, LOCALE_GENRE_TRAVEL_HOBBIES_3,0 }, - { 0xA4, LOCALE_GENRE_TRAVEL_HOBBIES_4,0 }, - { 0xA5, LOCALE_GENRE_TRAVEL_HOBBIES_5,0 }, - { 0xA6, LOCALE_GENRE_TRAVEL_HOBBIES_6,0 }, - { 0xA7, LOCALE_GENRE_TRAVEL_HOBBIES_7,0} + { 0x00, LOCALE_GENRE_UNKNOWN }, + { 0x10, LOCALE_GENRE_MOVIE_0 }, + { 0x11, LOCALE_GENRE_MOVIE_1 }, + { 0x12, LOCALE_GENRE_MOVIE_2 }, + { 0x13, LOCALE_GENRE_MOVIE_3 }, + { 0x14, LOCALE_GENRE_MOVIE_4 }, + { 0x15, LOCALE_GENRE_MOVIE_5 }, + { 0x16, LOCALE_GENRE_MOVIE_6 }, + { 0x17, LOCALE_GENRE_MOVIE_7 }, + { 0x18, LOCALE_GENRE_MOVIE_8 }, + { 0x20, LOCALE_GENRE_NEWS_0 }, + { 0x21, LOCALE_GENRE_NEWS_1 }, + { 0x22, LOCALE_GENRE_NEWS_2 }, + { 0x23, LOCALE_GENRE_NEWS_3 }, + { 0x24, LOCALE_GENRE_NEWS_4 }, + { 0x30, LOCALE_GENRE_SHOW_0 }, + { 0x31, LOCALE_GENRE_SHOW_1 }, + { 0x32, LOCALE_GENRE_SHOW_2 }, + { 0x33, LOCALE_GENRE_SHOW_3 }, + { 0x40, LOCALE_GENRE_SPORTS_0 }, + { 0x41, LOCALE_GENRE_SPORTS_1 }, + { 0x42, LOCALE_GENRE_SPORTS_2 }, + { 0x43, LOCALE_GENRE_SPORTS_3 }, + { 0x44, LOCALE_GENRE_SPORTS_4 }, + { 0x45, LOCALE_GENRE_SPORTS_5 }, + { 0x46, LOCALE_GENRE_SPORTS_6 }, + { 0x47, LOCALE_GENRE_SPORTS_7 }, + { 0x48, LOCALE_GENRE_SPORTS_8 }, + { 0x49, LOCALE_GENRE_SPORTS_9 }, + { 0x4A, LOCALE_GENRE_SPORTS_10 }, + { 0x4B, LOCALE_GENRE_SPORTS_11 }, + { 0x50, LOCALE_GENRE_CHILDRENS_PROGRAMMES_0 }, + { 0x51, LOCALE_GENRE_CHILDRENS_PROGRAMMES_1 }, + { 0x52, LOCALE_GENRE_CHILDRENS_PROGRAMMES_2 }, + { 0x53, LOCALE_GENRE_CHILDRENS_PROGRAMMES_3 }, + { 0x54, LOCALE_GENRE_CHILDRENS_PROGRAMMES_4 }, + { 0x55, LOCALE_GENRE_CHILDRENS_PROGRAMMES_5 }, + { 0x60, LOCALE_GENRE_MUSIC_DANCE_0 }, + { 0x61, LOCALE_GENRE_MUSIC_DANCE_1 }, + { 0x62, LOCALE_GENRE_MUSIC_DANCE_2 }, + { 0x63, LOCALE_GENRE_MUSIC_DANCE_3 }, + { 0x64, LOCALE_GENRE_MUSIC_DANCE_4 }, + { 0x65, LOCALE_GENRE_MUSIC_DANCE_5 }, + { 0x66, LOCALE_GENRE_MUSIC_DANCE_6 }, + { 0x70, LOCALE_GENRE_ARTS_0 }, + { 0x71, LOCALE_GENRE_ARTS_1 }, + { 0x72, LOCALE_GENRE_ARTS_2 }, + { 0x73, LOCALE_GENRE_ARTS_3 }, + { 0x74, LOCALE_GENRE_ARTS_4 }, + { 0x75, LOCALE_GENRE_ARTS_5 }, + { 0x76, LOCALE_GENRE_ARTS_6 }, + { 0x77, LOCALE_GENRE_ARTS_7 }, + { 0x78, LOCALE_GENRE_ARTS_8 }, + { 0x79, LOCALE_GENRE_ARTS_9 }, + { 0x7A, LOCALE_GENRE_ARTS_10 }, + { 0x7B, LOCALE_GENRE_ARTS_11 }, + { 0x80, LOCALE_GENRE_SOCIAL_POLITICAL_0 }, + { 0x81, LOCALE_GENRE_SOCIAL_POLITICAL_1 }, + { 0x82, LOCALE_GENRE_SOCIAL_POLITICAL_2 }, + { 0x83, LOCALE_GENRE_SOCIAL_POLITICAL_3 }, + { 0x90, LOCALE_GENRE_DOCUS_MAGAZINES_0 }, + { 0x91, LOCALE_GENRE_DOCUS_MAGAZINES_1 }, + { 0x92, LOCALE_GENRE_DOCUS_MAGAZINES_2 }, + { 0x93, LOCALE_GENRE_DOCUS_MAGAZINES_3 }, + { 0x94, LOCALE_GENRE_DOCUS_MAGAZINES_4 }, + { 0x95, LOCALE_GENRE_DOCUS_MAGAZINES_5 }, + { 0x96, LOCALE_GENRE_DOCUS_MAGAZINES_6 }, + { 0x97, LOCALE_GENRE_DOCUS_MAGAZINES_7 }, + { 0xA0, LOCALE_GENRE_TRAVEL_HOBBIES_0 }, + { 0xA1, LOCALE_GENRE_TRAVEL_HOBBIES_1 }, + { 0xA2, LOCALE_GENRE_TRAVEL_HOBBIES_2 }, + { 0xA3, LOCALE_GENRE_TRAVEL_HOBBIES_3 }, + { 0xA4, LOCALE_GENRE_TRAVEL_HOBBIES_4 }, + { 0xA5, LOCALE_GENRE_TRAVEL_HOBBIES_5 }, + { 0xA6, LOCALE_GENRE_TRAVEL_HOBBIES_6 }, + { 0xA7, LOCALE_GENRE_TRAVEL_HOBBIES_7 } }; #define GENRE_MOVIE_COUNT 9 const CMenuOptionChooser::keyval genre_movie[GENRE_MOVIE_COUNT] = { - { 0, LOCALE_GENRE_MOVIE_0,0 }, - { 1, LOCALE_GENRE_MOVIE_1,0 }, - { 2, LOCALE_GENRE_MOVIE_2,0 }, - { 3, LOCALE_GENRE_MOVIE_3,0 }, - { 4, LOCALE_GENRE_MOVIE_4,0 }, - { 5, LOCALE_GENRE_MOVIE_5,0 }, - { 6, LOCALE_GENRE_MOVIE_6,0 }, - { 7, LOCALE_GENRE_MOVIE_7,0 }, - { 8, LOCALE_GENRE_MOVIE_8,0 } + { 0, LOCALE_GENRE_MOVIE_0 }, + { 1, LOCALE_GENRE_MOVIE_1 }, + { 2, LOCALE_GENRE_MOVIE_2 }, + { 3, LOCALE_GENRE_MOVIE_3 }, + { 4, LOCALE_GENRE_MOVIE_4 }, + { 5, LOCALE_GENRE_MOVIE_5 }, + { 6, LOCALE_GENRE_MOVIE_6 }, + { 7, LOCALE_GENRE_MOVIE_7 }, + { 8, LOCALE_GENRE_MOVIE_8 } }; #define GENRE_NEWS_COUNT 5 const CMenuOptionChooser::keyval genre_news[GENRE_NEWS_COUNT] = { - { 0, LOCALE_GENRE_NEWS_0,0 }, - { 1, LOCALE_GENRE_NEWS_1,0 }, - { 2, LOCALE_GENRE_NEWS_2,0 }, - { 3, LOCALE_GENRE_NEWS_3,0 }, - { 4, LOCALE_GENRE_NEWS_4,0} + { 0, LOCALE_GENRE_NEWS_0 }, + { 1, LOCALE_GENRE_NEWS_1 }, + { 2, LOCALE_GENRE_NEWS_2 }, + { 3, LOCALE_GENRE_NEWS_3 }, + { 4, LOCALE_GENRE_NEWS_4 } }; #define GENRE_SHOW_COUNT 4 const CMenuOptionChooser::keyval genre_show[GENRE_SHOW_COUNT] = { - { 0, LOCALE_GENRE_SHOW_0,0 }, - { 1, LOCALE_GENRE_SHOW_1,0 }, - { 2, LOCALE_GENRE_SHOW_2,0 }, - { 3, LOCALE_GENRE_SHOW_3,0} + { 0, LOCALE_GENRE_SHOW_0 }, + { 1, LOCALE_GENRE_SHOW_1 }, + { 2, LOCALE_GENRE_SHOW_2 }, + { 3, LOCALE_GENRE_SHOW_3 } }; #define GENRE_SPORTS_COUNT 12 const CMenuOptionChooser::keyval genre_sports[GENRE_SPORTS_COUNT] = { - { 0, LOCALE_GENRE_SPORTS_0,0 }, - { 1, LOCALE_GENRE_SPORTS_1,0 }, - { 2, LOCALE_GENRE_SPORTS_2,0 }, - { 3, LOCALE_GENRE_SPORTS_3,0 }, - { 4, LOCALE_GENRE_SPORTS_4,0 }, - { 5, LOCALE_GENRE_SPORTS_5,0 }, - { 6, LOCALE_GENRE_SPORTS_6,0 }, - { 7, LOCALE_GENRE_SPORTS_7,0 }, - { 8, LOCALE_GENRE_SPORTS_8,0 }, - { 9, LOCALE_GENRE_SPORTS_9,0 }, - {10, LOCALE_GENRE_SPORTS_10,0 }, - {11, LOCALE_GENRE_SPORTS_11,0} + { 0, LOCALE_GENRE_SPORTS_0 }, + { 1, LOCALE_GENRE_SPORTS_1 }, + { 2, LOCALE_GENRE_SPORTS_2 }, + { 3, LOCALE_GENRE_SPORTS_3 }, + { 4, LOCALE_GENRE_SPORTS_4 }, + { 5, LOCALE_GENRE_SPORTS_5 }, + { 6, LOCALE_GENRE_SPORTS_6 }, + { 7, LOCALE_GENRE_SPORTS_7 }, + { 8, LOCALE_GENRE_SPORTS_8 }, + { 9, LOCALE_GENRE_SPORTS_9 }, + {10, LOCALE_GENRE_SPORTS_10 }, + {11, LOCALE_GENRE_SPORTS_11 } }; #define GENRE_CHILDRENS_PROGRAMMES_COUNT 6 const CMenuOptionChooser::keyval genre_childrens_programmes[GENRE_CHILDRENS_PROGRAMMES_COUNT] = { - { 0, LOCALE_GENRE_CHILDRENS_PROGRAMMES_0,0 }, - { 1, LOCALE_GENRE_CHILDRENS_PROGRAMMES_1,0 }, - { 2, LOCALE_GENRE_CHILDRENS_PROGRAMMES_2,0 }, - { 3, LOCALE_GENRE_CHILDRENS_PROGRAMMES_3,0 }, - { 4, LOCALE_GENRE_CHILDRENS_PROGRAMMES_4,0 }, - { 5, LOCALE_GENRE_CHILDRENS_PROGRAMMES_5,0} + { 0, LOCALE_GENRE_CHILDRENS_PROGRAMMES_0 }, + { 1, LOCALE_GENRE_CHILDRENS_PROGRAMMES_1 }, + { 2, LOCALE_GENRE_CHILDRENS_PROGRAMMES_2 }, + { 3, LOCALE_GENRE_CHILDRENS_PROGRAMMES_3 }, + { 4, LOCALE_GENRE_CHILDRENS_PROGRAMMES_4 }, + { 5, LOCALE_GENRE_CHILDRENS_PROGRAMMES_5 } }; #define GENRE_MUSIC_DANCE_COUNT 7 const CMenuOptionChooser::keyval genre_music_dance[GENRE_MUSIC_DANCE_COUNT] = { - { 0, LOCALE_GENRE_MUSIC_DANCE_0,0 }, - { 1, LOCALE_GENRE_MUSIC_DANCE_1,0 }, - { 2, LOCALE_GENRE_MUSIC_DANCE_2,0 }, - { 3, LOCALE_GENRE_MUSIC_DANCE_3,0 }, - { 4, LOCALE_GENRE_MUSIC_DANCE_4,0 }, - { 5, LOCALE_GENRE_MUSIC_DANCE_5,0 }, - { 6, LOCALE_GENRE_MUSIC_DANCE_6,0} + { 0, LOCALE_GENRE_MUSIC_DANCE_0 }, + { 1, LOCALE_GENRE_MUSIC_DANCE_1 }, + { 2, LOCALE_GENRE_MUSIC_DANCE_2 }, + { 3, LOCALE_GENRE_MUSIC_DANCE_3 }, + { 4, LOCALE_GENRE_MUSIC_DANCE_4 }, + { 5, LOCALE_GENRE_MUSIC_DANCE_5 }, + { 6, LOCALE_GENRE_MUSIC_DANCE_6 } }; #define GENRE_ARTS_COUNT 12 const CMenuOptionChooser::keyval genre_arts_dance[GENRE_ARTS_COUNT] = { - { 0, LOCALE_GENRE_ARTS_0,0 }, - { 1, LOCALE_GENRE_ARTS_1,0 }, - { 2, LOCALE_GENRE_ARTS_2,0 }, - { 3, LOCALE_GENRE_ARTS_3,0 }, - { 4, LOCALE_GENRE_ARTS_4,0 }, - { 5, LOCALE_GENRE_ARTS_5,0 }, - { 6, LOCALE_GENRE_ARTS_6,0 }, - { 7, LOCALE_GENRE_ARTS_7,0 }, - { 8, LOCALE_GENRE_ARTS_8,0 }, - { 9, LOCALE_GENRE_ARTS_9,0 }, - {10, LOCALE_GENRE_ARTS_10,0 }, - {11, LOCALE_GENRE_ARTS_11,0} + { 0, LOCALE_GENRE_ARTS_0 }, + { 1, LOCALE_GENRE_ARTS_1 }, + { 2, LOCALE_GENRE_ARTS_2 }, + { 3, LOCALE_GENRE_ARTS_3 }, + { 4, LOCALE_GENRE_ARTS_4 }, + { 5, LOCALE_GENRE_ARTS_5 }, + { 6, LOCALE_GENRE_ARTS_6 }, + { 7, LOCALE_GENRE_ARTS_7 }, + { 8, LOCALE_GENRE_ARTS_8 }, + { 9, LOCALE_GENRE_ARTS_9 }, + {10, LOCALE_GENRE_ARTS_10 }, + {11, LOCALE_GENRE_ARTS_11 } }; #define GENRE_SOCIAL_POLITICAL_COUNT 4 const CMenuOptionChooser::keyval genre_social_political[GENRE_SOCIAL_POLITICAL_COUNT] = { - { 0, LOCALE_GENRE_SOCIAL_POLITICAL_0,0 }, - { 1, LOCALE_GENRE_SOCIAL_POLITICAL_1,0 }, - { 2, LOCALE_GENRE_SOCIAL_POLITICAL_2,0 }, - { 3, LOCALE_GENRE_SOCIAL_POLITICAL_3,0} + { 0, LOCALE_GENRE_SOCIAL_POLITICAL_0 }, + { 1, LOCALE_GENRE_SOCIAL_POLITICAL_1 }, + { 2, LOCALE_GENRE_SOCIAL_POLITICAL_2 }, + { 3, LOCALE_GENRE_SOCIAL_POLITICAL_3 } }; #define GENRE_DOCUS_MAGAZINES_COUNT 8 const CMenuOptionChooser::keyval genre_docus_magazines[GENRE_DOCUS_MAGAZINES_COUNT] = { - { 0, LOCALE_GENRE_DOCUS_MAGAZINES_0,0 }, - { 1, LOCALE_GENRE_DOCUS_MAGAZINES_1,0 }, - { 2, LOCALE_GENRE_DOCUS_MAGAZINES_2,0 }, - { 3, LOCALE_GENRE_DOCUS_MAGAZINES_3,0 }, - { 4, LOCALE_GENRE_DOCUS_MAGAZINES_4,0 }, - { 5, LOCALE_GENRE_DOCUS_MAGAZINES_5,0 }, - { 6, LOCALE_GENRE_DOCUS_MAGAZINES_6,0 }, - { 7, LOCALE_GENRE_DOCUS_MAGAZINES_7,0} + { 0, LOCALE_GENRE_DOCUS_MAGAZINES_0 }, + { 1, LOCALE_GENRE_DOCUS_MAGAZINES_1 }, + { 2, LOCALE_GENRE_DOCUS_MAGAZINES_2 }, + { 3, LOCALE_GENRE_DOCUS_MAGAZINES_3 }, + { 4, LOCALE_GENRE_DOCUS_MAGAZINES_4 }, + { 5, LOCALE_GENRE_DOCUS_MAGAZINES_5 }, + { 6, LOCALE_GENRE_DOCUS_MAGAZINES_6 }, + { 7, LOCALE_GENRE_DOCUS_MAGAZINES_7 } }; #define GENRE_TRAVEL_HOBBIES_COUNT 8 const CMenuOptionChooser::keyval genre_travel_hobbies[GENRE_TRAVEL_HOBBIES_COUNT] = { - { 0, LOCALE_GENRE_TRAVEL_HOBBIES_0,0 }, - { 1, LOCALE_GENRE_TRAVEL_HOBBIES_1,0 }, - { 2, LOCALE_GENRE_TRAVEL_HOBBIES_2,0 }, - { 3, LOCALE_GENRE_TRAVEL_HOBBIES_3,0 }, - { 4, LOCALE_GENRE_TRAVEL_HOBBIES_4,0 }, - { 5, LOCALE_GENRE_TRAVEL_HOBBIES_5,0 }, - { 6, LOCALE_GENRE_TRAVEL_HOBBIES_6,0 }, - { 7, LOCALE_GENRE_TRAVEL_HOBBIES_7,0} + { 0, LOCALE_GENRE_TRAVEL_HOBBIES_0 }, + { 1, LOCALE_GENRE_TRAVEL_HOBBIES_1 }, + { 2, LOCALE_GENRE_TRAVEL_HOBBIES_2 }, + { 3, LOCALE_GENRE_TRAVEL_HOBBIES_3 }, + { 4, LOCALE_GENRE_TRAVEL_HOBBIES_4 }, + { 5, LOCALE_GENRE_TRAVEL_HOBBIES_5 }, + { 6, LOCALE_GENRE_TRAVEL_HOBBIES_6 }, + { 7, LOCALE_GENRE_TRAVEL_HOBBIES_7 } }; #define GENRE_MAJOR_COUNT 10 const CMenuOptionChooser::keyval genre_major[GENRE_MAJOR_COUNT] = { - { 1, LOCALE_GENRE_MOVIE_0,0 }, - { 2, LOCALE_GENRE_NEWS_0,0 }, - { 3, LOCALE_GENRE_SHOW_0,0 }, - { 4, LOCALE_GENRE_SPORTS_0,0 }, - { 5, LOCALE_GENRE_CHILDRENS_PROGRAMMES_0,0 }, - { 6, LOCALE_GENRE_MUSIC_DANCE_0,0 }, - { 7, LOCALE_GENRE_ARTS_0,0 }, - { 8, LOCALE_GENRE_SOCIAL_POLITICAL_0,0 }, - { 9, LOCALE_GENRE_DOCUS_MAGAZINES_0,0 }, - { 10, LOCALE_GENRE_TRAVEL_HOBBIES_0,0} + { 1, LOCALE_GENRE_MOVIE_0 }, + { 2, LOCALE_GENRE_NEWS_0 }, + { 3, LOCALE_GENRE_SHOW_0 }, + { 4, LOCALE_GENRE_SPORTS_0 }, + { 5, LOCALE_GENRE_CHILDRENS_PROGRAMMES_0 }, + { 6, LOCALE_GENRE_MUSIC_DANCE_0 }, + { 7, LOCALE_GENRE_ARTS_0 }, + { 8, LOCALE_GENRE_SOCIAL_POLITICAL_0 }, + { 9, LOCALE_GENRE_DOCUS_MAGAZINES_0 }, + { 10, LOCALE_GENRE_TRAVEL_HOBBIES_0} }; diff --git a/src/gui/nfs.cpp b/src/gui/nfs.cpp index 0fd76867e..5e3dd15b0 100644 --- a/src/gui/nfs.cpp +++ b/src/gui/nfs.cpp @@ -199,16 +199,16 @@ int CNFSMountGui::menu() #define MESSAGEBOX_NO_YES_OPTION_COUNT 2 const CMenuOptionChooser::keyval MESSAGEBOX_NO_YES_OPTIONS[MESSAGEBOX_NO_YES_OPTION_COUNT] = { - { 0, LOCALE_MESSAGEBOX_NO ,0}, - { 1, LOCALE_MESSAGEBOX_YES ,0} + { 0, LOCALE_MESSAGEBOX_NO }, + { 1, LOCALE_MESSAGEBOX_YES } }; #define NFS_TYPE_OPTION_COUNT 3 const CMenuOptionChooser::keyval NFS_TYPE_OPTIONS[NFS_TYPE_OPTION_COUNT] = { - { CFSMounter::NFS , LOCALE_NFS_TYPE_NFS ,0}, - { CFSMounter::CIFS, LOCALE_NFS_TYPE_CIFS ,0} /*, - { CFSMounter::LUFS, LOCALE_NFS_TYPE_LUFS ,0} */ + { CFSMounter::NFS , LOCALE_NFS_TYPE_NFS }, + { CFSMounter::CIFS, LOCALE_NFS_TYPE_CIFS } /*, + { CFSMounter::LUFS, LOCALE_NFS_TYPE_LUFS } */ }; int CNFSMountGui::menuEntry(int nr) diff --git a/src/gui/timerlist.cpp b/src/gui/timerlist.cpp index dbd56a9ba..17c9d4439 100644 --- a/src/gui/timerlist.cpp +++ b/src/gui/timerlist.cpp @@ -893,20 +893,20 @@ std::string CTimerList::convertChannelId2String(const t_channel_id id) // UTF-8 #define TIMERLIST_REPEAT_OPTION_COUNT 7 const CMenuOptionChooser::keyval TIMERLIST_REPEAT_OPTIONS[TIMERLIST_REPEAT_OPTION_COUNT] = { - { CTimerd::TIMERREPEAT_ONCE , LOCALE_TIMERLIST_REPEAT_ONCE ,0}, - { CTimerd::TIMERREPEAT_DAILY , LOCALE_TIMERLIST_REPEAT_DAILY ,0}, - { CTimerd::TIMERREPEAT_WEEKLY , LOCALE_TIMERLIST_REPEAT_WEEKLY ,0}, - { CTimerd::TIMERREPEAT_BIWEEKLY , LOCALE_TIMERLIST_REPEAT_BIWEEKLY ,0}, - { CTimerd::TIMERREPEAT_FOURWEEKLY , LOCALE_TIMERLIST_REPEAT_FOURWEEKLY ,0}, - { CTimerd::TIMERREPEAT_MONTHLY , LOCALE_TIMERLIST_REPEAT_MONTHLY ,0}, - { CTimerd::TIMERREPEAT_WEEKDAYS , LOCALE_TIMERLIST_REPEAT_WEEKDAYS ,0} + { CTimerd::TIMERREPEAT_ONCE, LOCALE_TIMERLIST_REPEAT_ONCE }, + { CTimerd::TIMERREPEAT_DAILY, LOCALE_TIMERLIST_REPEAT_DAILY }, + { CTimerd::TIMERREPEAT_WEEKLY, LOCALE_TIMERLIST_REPEAT_WEEKLY }, + { CTimerd::TIMERREPEAT_BIWEEKLY, LOCALE_TIMERLIST_REPEAT_BIWEEKLY }, + { CTimerd::TIMERREPEAT_FOURWEEKLY, LOCALE_TIMERLIST_REPEAT_FOURWEEKLY }, + { CTimerd::TIMERREPEAT_MONTHLY, LOCALE_TIMERLIST_REPEAT_MONTHLY }, + { CTimerd::TIMERREPEAT_WEEKDAYS, LOCALE_TIMERLIST_REPEAT_WEEKDAYS } }; #define TIMERLIST_STANDBY_OPTION_COUNT 2 const CMenuOptionChooser::keyval TIMERLIST_STANDBY_OPTIONS[TIMERLIST_STANDBY_OPTION_COUNT] = { - { 0 , LOCALE_TIMERLIST_STANDBY_OFF ,0}, - { 1 , LOCALE_TIMERLIST_STANDBY_ON ,0} + { 0, LOCALE_TIMERLIST_STANDBY_OFF }, + { 1, LOCALE_TIMERLIST_STANDBY_ON } }; #if 1 @@ -916,23 +916,23 @@ const CMenuOptionChooser::keyval TIMERLIST_STANDBY_OPTIONS[TIMERLIST_STANDBY_OPT #endif const CMenuOptionChooser::keyval TIMERLIST_TYPE_OPTIONS[TIMERLIST_TYPE_OPTION_COUNT] = { - { CTimerd::TIMER_SHUTDOWN , LOCALE_TIMERLIST_TYPE_SHUTDOWN ,0}, + { CTimerd::TIMER_SHUTDOWN, LOCALE_TIMERLIST_TYPE_SHUTDOWN }, #if 0 - { CTimerd::TIMER_NEXTPROGRAM, LOCALE_TIMERLIST_TYPE_NEXTPROGRAM }, + { CTimerd::TIMER_NEXTPROGRAM, LOCALE_TIMERLIST_TYPE_NEXTPROGRAM }, #endif - { CTimerd::TIMER_ZAPTO , LOCALE_TIMERLIST_TYPE_ZAPTO ,0}, - { CTimerd::TIMER_STANDBY , LOCALE_TIMERLIST_TYPE_STANDBY ,0}, - { CTimerd::TIMER_RECORD , LOCALE_TIMERLIST_TYPE_RECORD ,0}, - { CTimerd::TIMER_SLEEPTIMER , LOCALE_TIMERLIST_TYPE_SLEEPTIMER ,0}, - { CTimerd::TIMER_REMIND , LOCALE_TIMERLIST_TYPE_REMIND ,0}, - { CTimerd::TIMER_EXEC_PLUGIN, LOCALE_TIMERLIST_TYPE_EXECPLUGIN ,0} + { CTimerd::TIMER_ZAPTO, LOCALE_TIMERLIST_TYPE_ZAPTO }, + { CTimerd::TIMER_STANDBY, LOCALE_TIMERLIST_TYPE_STANDBY }, + { CTimerd::TIMER_RECORD, LOCALE_TIMERLIST_TYPE_RECORD }, + { CTimerd::TIMER_SLEEPTIMER, LOCALE_TIMERLIST_TYPE_SLEEPTIMER }, + { CTimerd::TIMER_REMIND, LOCALE_TIMERLIST_TYPE_REMIND }, + { CTimerd::TIMER_EXEC_PLUGIN, LOCALE_TIMERLIST_TYPE_EXECPLUGIN } }; #define MESSAGEBOX_NO_YES_OPTION_COUNT 2 const CMenuOptionChooser::keyval MESSAGEBOX_NO_YES_OPTIONS[MESSAGEBOX_NO_YES_OPTION_COUNT] = { - { 0, LOCALE_MESSAGEBOX_NO ,0}, - { 1, LOCALE_MESSAGEBOX_YES ,0} + { 0, LOCALE_MESSAGEBOX_NO }, + { 1, LOCALE_MESSAGEBOX_YES } }; int CTimerList::modifyTimer() diff --git a/src/gui/widget/menue.cpp b/src/gui/widget/menue.cpp index ab57bb959..a1c64a2a3 100644 --- a/src/gui/widget/menue.cpp +++ b/src/gui/widget/menue.cpp @@ -643,7 +643,6 @@ CMenuOptionChooser::CMenuOptionChooser(const neutrino_locale_t OptionName, int * height = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getHeight(); optionNameString = g_Locale->getText(OptionName); optionName = OptionName; - options = Options; active = Active; optionValue = OptionValue; number_of_options = Number_Of_Options; @@ -652,6 +651,14 @@ CMenuOptionChooser::CMenuOptionChooser(const neutrino_locale_t OptionName, int * iconName = IconName; can_arrow = true; pulldown = Pulldown; + for (unsigned int i = 0; i < number_of_options; i++) + { + struct keyval_ext opt; + opt.key = Options[i].key; + opt.value = Options[i].value; + opt.valname = NULL; + options.push_back(opt); + } } CMenuOptionChooser::CMenuOptionChooser(const char* OptionName, int * const OptionValue, const struct keyval * const Options, const unsigned Number_Of_Options, const bool Active, CChangeObserver * const Observ, const neutrino_msg_t DirectKey, const std::string & IconName, bool Pulldown) @@ -659,7 +666,6 @@ CMenuOptionChooser::CMenuOptionChooser(const char* OptionName, int * const Optio height = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getHeight(); optionNameString = OptionName; optionName = NONEXISTANT_LOCALE; - options = Options; active = Active; optionValue = OptionValue; number_of_options = Number_Of_Options; @@ -668,6 +674,57 @@ CMenuOptionChooser::CMenuOptionChooser(const char* OptionName, int * const Optio iconName = IconName; can_arrow = true; pulldown = Pulldown; + for (unsigned int i = 0; i < number_of_options; i++) + { + struct keyval_ext opt; + opt.key = Options[i].key; + opt.value = Options[i].value; + opt.valname = NULL; + options.push_back(opt); + } +} + +CMenuOptionChooser::CMenuOptionChooser(const neutrino_locale_t OptionName, int * const OptionValue, const struct keyval_ext * const Options, + const unsigned Number_Of_Options, const bool Active, CChangeObserver * const Observ, + const neutrino_msg_t DirectKey, const std::string & IconName, bool Pulldown) +{ + height = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getHeight(); + optionNameString = g_Locale->getText(OptionName); + optionName = OptionName; + active = Active; + optionValue = OptionValue; + number_of_options = Number_Of_Options; + observ = Observ; + directKey = DirectKey; + iconName = IconName; + can_arrow = true; + pulldown = Pulldown; + for (unsigned int i = 0; i < number_of_options; i++) + options.push_back(Options[i]); +} + +CMenuOptionChooser::CMenuOptionChooser(const char* OptionName, int * const OptionValue, const struct keyval_ext * const Options, + const unsigned Number_Of_Options, const bool Active, CChangeObserver * const Observ, + const neutrino_msg_t DirectKey, const std::string & IconName, bool Pulldown) +{ + height = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getHeight(); + optionNameString = OptionName; + optionName = NONEXISTANT_LOCALE; + active = Active; + optionValue = OptionValue; + number_of_options = Number_Of_Options; + observ = Observ; + directKey = DirectKey; + iconName = IconName; + can_arrow = true; + pulldown = Pulldown; + for (unsigned int i = 0; i < number_of_options; i++) + options.push_back(Options[i]); +} + +CMenuOptionChooser::~CMenuOptionChooser() +{ + options.clear(); } void CMenuOptionChooser::setOptionValue(const int newvalue) diff --git a/src/gui/widget/menue.h b/src/gui/widget/menue.h index 2aa6196a8..92f9beb53 100644 --- a/src/gui/widget/menue.h +++ b/src/gui/widget/menue.h @@ -223,23 +223,44 @@ class CMenuOptionNumberChooser : public CAbstractMenuOptionChooser class CMenuOptionChooser : public CAbstractMenuOptionChooser { public: + struct keyval_ext + { + int key; + neutrino_locale_t value; + const char *valname; + }; + struct keyval { const int key; const neutrino_locale_t value; - const char * valname; }; private: - const struct keyval * options; + std::vector options; unsigned number_of_options; CChangeObserver * observ; std::string optionNameString; bool pulldown; public: - CMenuOptionChooser(const neutrino_locale_t OptionName, int * const OptionValue, const struct keyval * const Options, const unsigned Number_Of_Options, const bool Active = false, CChangeObserver * const Observ = NULL, const neutrino_msg_t DirectKey = CRCInput::RC_nokey, const std::string & IconName= "", bool Pulldown = false); - CMenuOptionChooser(const char* OptionName, int * const OptionValue, const struct keyval * const Options, const unsigned Number_Of_Options, const bool Active = false, CChangeObserver * const Observ = NULL, const neutrino_msg_t DirectKey = CRCInput::RC_nokey, const std::string & IconName= "", bool Pulldown = false); + CMenuOptionChooser(const neutrino_locale_t OptionName, int * const OptionValue, const struct keyval * const Options, + const unsigned Number_Of_Options, const bool Active = false, CChangeObserver * const Observ = NULL, + const neutrino_msg_t DirectKey = CRCInput::RC_nokey, const std::string & IconName= "", + bool Pulldown = false); + CMenuOptionChooser(const neutrino_locale_t OptionName, int * const OptionValue, const struct keyval_ext * const Options, + const unsigned Number_Of_Options, const bool Active = false, CChangeObserver * const Observ = NULL, + const neutrino_msg_t DirectKey = CRCInput::RC_nokey, const std::string & IconName= "", + bool Pulldown = false); + CMenuOptionChooser(const char* OptionName, int * const OptionValue, const struct keyval * const Options, + const unsigned Number_Of_Options, const bool Active = false, CChangeObserver * const Observ = NULL, + const neutrino_msg_t DirectKey = CRCInput::RC_nokey, const std::string & IconName= "", + bool Pulldown = false); + CMenuOptionChooser(const char* OptionName, int * const OptionValue, const struct keyval_ext * const Options, + const unsigned Number_Of_Options, const bool Active = false, CChangeObserver * const Observ = NULL, + const neutrino_msg_t DirectKey = CRCInput::RC_nokey, const std::string & IconName= "", + bool Pulldown = false); + ~CMenuOptionChooser(); void setOptionValue(const int newvalue); int getOptionValue(void) const; diff --git a/src/mymenu.h b/src/mymenu.h index 2e9c26dce..b64567043 100644 --- a/src/mymenu.h +++ b/src/mymenu.h @@ -1,63 +1,63 @@ #define SCANMODE_OPTION_COUNT 3 const CMenuOptionChooser::keyval SCANMODE_OPTIONS[SCANMODE_OPTION_COUNT] = { - { 0, LOCALE_EXTRA_SCAN_FULL,0}, - { 1, LOCALE_EXTRA_SCAN_FAST,0}, - { 2, LOCALE_EXTRA_TPSCAN,0} + { 0, LOCALE_EXTRA_SCAN_FULL }, + { 1, LOCALE_EXTRA_SCAN_FAST }, + { 2, LOCALE_EXTRA_TPSCAN } }; #define HDD_NOISE_OPTION_COUNT 4 const CMenuOptionChooser::keyval HDD_NOISE_OPTIONS[HDD_NOISE_OPTION_COUNT] = { - {0, LOCALE_OPTIONS_OFF ,0 }, - {128, LOCALE_HDD_SLOW ,0 }, - {190, LOCALE_HDD_MIDDLE ,0 }, - {254, LOCALE_HDD_FAST ,0 } + { 0, LOCALE_OPTIONS_OFF }, + { 128, LOCALE_HDD_SLOW }, + { 190, LOCALE_HDD_MIDDLE }, + { 254, LOCALE_HDD_FAST } }; #define HDD_FILESYS_OPTION_COUNT 3 const CMenuOptionChooser::keyval HDD_FILESYS_OPTIONS[HDD_FILESYS_OPTION_COUNT] = { - {0, LOCALE_HDD_EXT3 ,0 }, - {1, LOCALE_HDD_REISER ,0 }, - {2, LOCALE_OPTIONS_OFF ,0 } + { 0, LOCALE_HDD_EXT3 }, + { 1, LOCALE_HDD_REISER }, + { 2, LOCALE_OPTIONS_OFF } }; #define HDD_SLEEP_OPTION_COUNT 7 const CMenuOptionChooser::keyval HDD_SLEEP_OPTIONS[HDD_SLEEP_OPTION_COUNT] = { - {0, LOCALE_OPTIONS_OFF ,0 }, - {12, LOCALE_HDD_1MIN ,0 }, - {60, LOCALE_HDD_5MIN ,0 }, - {120, LOCALE_HDD_10MIN ,0 }, - {240, LOCALE_HDD_20MIN ,0 }, - {241, LOCALE_HDD_30MIN ,0 }, - {242, LOCALE_HDD_60MIN ,0 } + { 0, LOCALE_OPTIONS_OFF }, + { 12, LOCALE_HDD_1MIN }, + { 60, LOCALE_HDD_5MIN }, + { 120, LOCALE_HDD_10MIN }, + { 240, LOCALE_HDD_20MIN }, + { 241, LOCALE_HDD_30MIN }, + { 242, LOCALE_HDD_60MIN } }; #if 0 #define LOGO_OPTION_COUNT 3 const CMenuOptionChooser::keyval LOGO_OPTIONS[LOGO_OPTION_COUNT] = { - {1, LOCALE_EXTRA_LOGO1 ,0 }, - {2, LOCALE_EXTRA_LOGO2 ,0 }, - {3, LOCALE_EXTRA_LOGO3 ,0 } + { 1, LOCALE_EXTRA_LOGO1 }, + { 2, LOCALE_EXTRA_LOGO2 }, + { 3, LOCALE_EXTRA_LOGO3 } }; #endif #define RF_CARRIER_OPTION_COUNT 4 const CMenuOptionChooser::keyval RF_CARRIER_OPTIONS[RF_CARRIER_OPTION_COUNT] = { - {0, LOCALE_RF_CARRIER_4500 ,0 }, - {1, LOCALE_RF_CARRIER_5500 ,0 }, - {2, LOCALE_RF_CARRIER_6000 ,0 }, - {3, LOCALE_RF_CARRIER_6500 ,0 } + { 0, LOCALE_RF_CARRIER_4500 }, + { 1, LOCALE_RF_CARRIER_5500 }, + { 2, LOCALE_RF_CARRIER_6000 }, + { 3, LOCALE_RF_CARRIER_6500 } }; #define OPTIONS_SOUTH0_NORTH1_OPTION_COUNT 2 const CMenuOptionChooser::keyval OPTIONS_SOUTH0_NORTH1_OPTIONS[OPTIONS_SOUTH0_NORTH1_OPTION_COUNT] = { - {0, LOCALE_EXTRA_SOUTH ,0 }, - {1, LOCALE_EXTRA_NORTH ,0 } + { 0, LOCALE_EXTRA_SOUTH }, + { 1, LOCALE_EXTRA_NORTH } }; #define OPTIONS_EAST0_WEST1_OPTION_COUNT 2 const CMenuOptionChooser::keyval OPTIONS_EAST0_WEST1_OPTIONS[OPTIONS_EAST0_WEST1_OPTION_COUNT] = { - {0, LOCALE_EXTRA_EAST ,0 }, - {1, LOCALE_EXTRA_WEST ,0 } + { 0, LOCALE_EXTRA_EAST }, + { 1, LOCALE_EXTRA_WEST } }; diff --git a/src/neutrino_menue.cpp b/src/neutrino_menue.cpp index 7c7e80682..4b81b4cdf 100644 --- a/src/neutrino_menue.cpp +++ b/src/neutrino_menue.cpp @@ -241,7 +241,7 @@ const CMenuOptionChooser::keyval VIDEOMENU_43MODE_OPTIONS[VIDEOMENU_43MODE_OPTIO /* numbers corresponding to video.cpp from zapit */ //#define VIDEOMENU_VIDEOMODE_OPTION_COUNT 11 -const CMenuOptionChooser::keyval VIDEOMENU_VIDEOMODE_OPTIONS[VIDEOMENU_VIDEOMODE_OPTION_COUNT] = +const CMenuOptionChooser::keyval_ext VIDEOMENU_VIDEOMODE_OPTIONS[VIDEOMENU_VIDEOMODE_OPTION_COUNT] = { { 1, NONEXISTANT_LOCALE, "SECAM" }, { 2, NONEXISTANT_LOCALE, "PAL" }, @@ -818,13 +818,13 @@ const CMenuOptionChooser::keyval SCANTS_ZAPIT_SCANTYPE[SCANTS_ZAPIT_SCANTYPE_COU #define SATSETUP_DISEQC_OPTION_COUNT 6 const CMenuOptionChooser::keyval SATSETUP_DISEQC_OPTIONS[SATSETUP_DISEQC_OPTION_COUNT] = { - { NO_DISEQC , LOCALE_SATSETUP_NODISEQC, NULL }, - { MINI_DISEQC , LOCALE_SATSETUP_MINIDISEQC, NULL }, - { DISEQC_1_0 , LOCALE_SATSETUP_DISEQC10, NULL }, - { DISEQC_1_1 , LOCALE_SATSETUP_DISEQC11, NULL }, - /*{ DISEQC_1_2 , LOCALE_SATSETUP_DISEQC12, NULL },*/ - { DISEQC_ADVANCED , LOCALE_SATSETUP_DISEQ_ADVANCED, NULL }, - { SMATV_REMOTE_TUNING, LOCALE_SATSETUP_SMATVREMOTE, NULL } + { NO_DISEQC, LOCALE_SATSETUP_NODISEQC }, + { MINI_DISEQC, LOCALE_SATSETUP_MINIDISEQC }, + { DISEQC_1_0, LOCALE_SATSETUP_DISEQC10 }, + { DISEQC_1_1, LOCALE_SATSETUP_DISEQC11 }, + /*{ DISEQC_1_2, LOCALE_SATSETUP_DISEQC12 },*/ + { DISEQC_ADVANCED, LOCALE_SATSETUP_DISEQ_ADVANCED }, + { SMATV_REMOTE_TUNING, LOCALE_SATSETUP_SMATVREMOTE } }; #define SATSETUP_SCANTP_FEC_COUNT 23 @@ -1453,9 +1453,9 @@ const CMenuOptionChooser::keyval CHANNELLIST_EPGTEXT_ALIGN_RIGHT_OPTIONS[CHANNE }; #define CPU_FREQ_OPTION_COUNT 13 -const CMenuOptionChooser::keyval CPU_FREQ_OPTIONS[CPU_FREQ_OPTION_COUNT] = +const CMenuOptionChooser::keyval_ext CPU_FREQ_OPTIONS[CPU_FREQ_OPTION_COUNT] = { - { 0, LOCALE_CPU_FREQ_DEFAULT }, + { 0, LOCALE_CPU_FREQ_DEFAULT, NULL }, { 50, NONEXISTANT_LOCALE, "50 Mhz"}, { 100, NONEXISTANT_LOCALE, "100 Mhz"}, { 150, NONEXISTANT_LOCALE, "150 Mhz"}, diff --git a/src/system/setting_helpers.cpp b/src/system/setting_helpers.cpp index 310c6bb8d..8ba9830ec 100644 --- a/src/system/setting_helpers.cpp +++ b/src/system/setting_helpers.cpp @@ -812,25 +812,25 @@ unsigned long long getcurrenttime() #define USERMENU_ITEM_OPTION_COUNT SNeutrinoSettings::ITEM_MAX const CMenuOptionChooser::keyval USERMENU_ITEM_OPTIONS[USERMENU_ITEM_OPTION_COUNT] = { - {SNeutrinoSettings::ITEM_NONE, LOCALE_USERMENU_ITEM_NONE,0} , - {SNeutrinoSettings::ITEM_BAR, LOCALE_USERMENU_ITEM_BAR,0} , - {SNeutrinoSettings::ITEM_EPG_LIST, LOCALE_EPGMENU_EVENTLIST,0} , - {SNeutrinoSettings::ITEM_EPG_SUPER, LOCALE_EPGMENU_EPGPLUS,0} , - {SNeutrinoSettings::ITEM_EPG_INFO, LOCALE_EPGMENU_EVENTINFO,0} , - {SNeutrinoSettings::ITEM_EPG_MISC, LOCALE_USERMENU_ITEM_EPG_MISC,0} , - {SNeutrinoSettings::ITEM_AUDIO_SELECT, LOCALE_AUDIOSELECTMENUE_HEAD,0} , - {SNeutrinoSettings::ITEM_SUBCHANNEL, LOCALE_INFOVIEWER_SUBSERVICE,0} , - {SNeutrinoSettings::ITEM_RECORD, LOCALE_TIMERLIST_TYPE_RECORD,0} , - {SNeutrinoSettings::ITEM_MOVIEPLAYER_MB, LOCALE_MOVIEBROWSER_HEAD,0} , - {SNeutrinoSettings::ITEM_TIMERLIST, LOCALE_TIMERLIST_NAME,0} , - {SNeutrinoSettings::ITEM_REMOTE, LOCALE_RCLOCK_MENUEADD,0} , - {SNeutrinoSettings::ITEM_FAVORITS, LOCALE_FAVORITES_MENUEADD,0} , - {SNeutrinoSettings::ITEM_TECHINFO, LOCALE_EPGMENU_STREAMINFO,0}, - {SNeutrinoSettings::ITEM_PLUGIN, LOCALE_TIMERLIST_PLUGIN,0}, - {SNeutrinoSettings::ITEM_VTXT, LOCALE_USERMENU_ITEM_VTXT,0} , + { SNeutrinoSettings::ITEM_NONE, LOCALE_USERMENU_ITEM_NONE }, + { SNeutrinoSettings::ITEM_BAR, LOCALE_USERMENU_ITEM_BAR }, + { SNeutrinoSettings::ITEM_EPG_LIST, LOCALE_EPGMENU_EVENTLIST }, + { SNeutrinoSettings::ITEM_EPG_SUPER, LOCALE_EPGMENU_EPGPLUS }, + { SNeutrinoSettings::ITEM_EPG_INFO, LOCALE_EPGMENU_EVENTINFO }, + { SNeutrinoSettings::ITEM_EPG_MISC, LOCALE_USERMENU_ITEM_EPG_MISC }, + { SNeutrinoSettings::ITEM_AUDIO_SELECT, LOCALE_AUDIOSELECTMENUE_HEAD }, + { SNeutrinoSettings::ITEM_SUBCHANNEL, LOCALE_INFOVIEWER_SUBSERVICE }, + { SNeutrinoSettings::ITEM_RECORD, LOCALE_TIMERLIST_TYPE_RECORD }, + { SNeutrinoSettings::ITEM_MOVIEPLAYER_MB, LOCALE_MOVIEBROWSER_HEAD }, + { SNeutrinoSettings::ITEM_TIMERLIST, LOCALE_TIMERLIST_NAME }, + { SNeutrinoSettings::ITEM_REMOTE, LOCALE_RCLOCK_MENUEADD }, + { SNeutrinoSettings::ITEM_FAVORITS, LOCALE_FAVORITES_MENUEADD }, + { SNeutrinoSettings::ITEM_TECHINFO, LOCALE_EPGMENU_STREAMINFO }, + { SNeutrinoSettings::ITEM_PLUGIN, LOCALE_TIMERLIST_PLUGIN }, + { SNeutrinoSettings::ITEM_VTXT, LOCALE_USERMENU_ITEM_VTXT }, #if 0 - {SNeutrinoSettings::ITEM_MOVIEPLAYER_TS, LOCALE_MAINMENU_MOVIEPLAYER,0} , - {SNeutrinoSettings::ITEM_RESTART_CAMD, LOCALE_EXTRA_RESTARTCAMD,0} + { SNeutrinoSettings::ITEM_MOVIEPLAYER_TS, LOCALE_MAINMENU_MOVIEPLAYER } , + { SNeutrinoSettings::ITEM_RESTART_CAMD, LOCALE_EXTRA_RESTARTCAMD } #endif };