mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-29 08:21:12 +02:00
GUI: add show menu hint option
This commit is contained in:
@@ -435,6 +435,8 @@ int COsdSetup::showOsdSetup()
|
|||||||
osd_menu->addItem(new CMenuOptionChooser(LOCALE_EXTRA_VOLUME_POS, &g_settings.volume_pos, VOLUMEBAR_DISP_POS_OPTIONS, VOLUMEBAR_DISP_POS_OPTIONS_COUNT, true, this));
|
osd_menu->addItem(new CMenuOptionChooser(LOCALE_EXTRA_VOLUME_POS, &g_settings.volume_pos, VOLUMEBAR_DISP_POS_OPTIONS, VOLUMEBAR_DISP_POS_OPTIONS_COUNT, true, this));
|
||||||
osd_menu->addItem(new CMenuOptionChooser(LOCALE_EXTRA_SHOW_MUTE_ICON, &g_settings.show_mute_icon, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true));
|
osd_menu->addItem(new CMenuOptionChooser(LOCALE_EXTRA_SHOW_MUTE_ICON, &g_settings.show_mute_icon, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true));
|
||||||
osd_menu->addItem(new CMenuOptionChooser(LOCALE_SETTINGS_MENU_POS, &g_settings.menu_pos, MENU_DISP_POS_OPTIONS, MENU_DISP_POS_OPTIONS_COUNT, true, this));
|
osd_menu->addItem(new CMenuOptionChooser(LOCALE_SETTINGS_MENU_POS, &g_settings.menu_pos, MENU_DISP_POS_OPTIONS, MENU_DISP_POS_OPTIONS_COUNT, true, this));
|
||||||
|
int show_hints = g_settings.show_menu_hints;
|
||||||
|
osd_menu->addItem(new CMenuOptionChooser(LOCALE_SETTINGS_MENU_HINTS, &show_hints, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true, this));
|
||||||
osd_menu->addItem(new CMenuOptionChooser(LOCALE_COLORMENU_FADE, &g_settings.widget_fade, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true ));
|
osd_menu->addItem(new CMenuOptionChooser(LOCALE_COLORMENU_FADE, &g_settings.widget_fade, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true ));
|
||||||
osd_menu->addItem(new CMenuOptionChooser(LOCALE_EXTRA_BIGWINDOWS, &g_settings.big_windows, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true));
|
osd_menu->addItem(new CMenuOptionChooser(LOCALE_EXTRA_BIGWINDOWS, &g_settings.big_windows, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true));
|
||||||
osd_menu->addItem(new CMenuOptionChooser(LOCALE_PROGRESSBAR_COLOR, &g_settings.progressbar_color, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true));
|
osd_menu->addItem(new CMenuOptionChooser(LOCALE_PROGRESSBAR_COLOR, &g_settings.progressbar_color, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true));
|
||||||
@@ -642,6 +644,12 @@ bool COsdSetup::changeNotify(const neutrino_locale_t OptionName, void * data)
|
|||||||
osd_menu->hide();
|
osd_menu->hide();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
else if (ARE_LOCALES_EQUAL(OptionName, LOCALE_SETTINGS_MENU_HINTS)) {
|
||||||
|
/* change option after hide, to let hide clear hint */
|
||||||
|
osd_menu->hide();
|
||||||
|
g_settings.show_menu_hints = * (int*) data;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
else if((ARE_LOCALES_EQUAL(OptionName, LOCALE_MISCSETTINGS_INFOBAR_CASYSTEM_DISPLAY)) ||
|
else if((ARE_LOCALES_EQUAL(OptionName, LOCALE_MISCSETTINGS_INFOBAR_CASYSTEM_DISPLAY)) ||
|
||||||
(ARE_LOCALES_EQUAL(OptionName, LOCALE_MISCSETTINGS_INFOBAR_SHOW_TUNER))) {
|
(ARE_LOCALES_EQUAL(OptionName, LOCALE_MISCSETTINGS_INFOBAR_SHOW_TUNER))) {
|
||||||
if (g_InfoViewer == NULL)
|
if (g_InfoViewer == NULL)
|
||||||
|
@@ -404,6 +404,7 @@ int CNeutrinoApp::loadSetup(const char * fname)
|
|||||||
g_settings.scrambled_message = configfile.getBool("scrambled_message", true );
|
g_settings.scrambled_message = configfile.getBool("scrambled_message", true );
|
||||||
g_settings.volume_pos = configfile.getInt32("volume_pos", 0 );
|
g_settings.volume_pos = configfile.getInt32("volume_pos", 0 );
|
||||||
g_settings.menu_pos = configfile.getInt32("menu_pos", CMenuWidget::MENU_POS_CENTER);
|
g_settings.menu_pos = configfile.getInt32("menu_pos", CMenuWidget::MENU_POS_CENTER);
|
||||||
|
g_settings.show_menu_hints = configfile.getBool("show_menu_hints", true);
|
||||||
g_settings.infobar_show_sysfs_hdd = configfile.getBool("infobar_show_sysfs_hdd" , true );
|
g_settings.infobar_show_sysfs_hdd = configfile.getBool("infobar_show_sysfs_hdd" , true );
|
||||||
g_settings.show_mute_icon = configfile.getInt32("show_mute_icon" ,0);
|
g_settings.show_mute_icon = configfile.getInt32("show_mute_icon" ,0);
|
||||||
g_settings.infobar_show_res = configfile.getInt32("infobar_show_res", 0 );
|
g_settings.infobar_show_res = configfile.getInt32("infobar_show_res", 0 );
|
||||||
@@ -845,6 +846,7 @@ void CNeutrinoApp::saveSetup(const char * fname)
|
|||||||
configfile.setBool("scrambled_message" , g_settings.scrambled_message );
|
configfile.setBool("scrambled_message" , g_settings.scrambled_message );
|
||||||
configfile.setInt32("volume_pos" , g_settings.volume_pos );
|
configfile.setInt32("volume_pos" , g_settings.volume_pos );
|
||||||
configfile.setInt32("menu_pos" , g_settings.menu_pos);
|
configfile.setInt32("menu_pos" , g_settings.menu_pos);
|
||||||
|
configfile.setBool("show_menu_hints" , g_settings.show_menu_hints);
|
||||||
configfile.setInt32("infobar_show_sysfs_hdd" , g_settings.infobar_show_sysfs_hdd );
|
configfile.setInt32("infobar_show_sysfs_hdd" , g_settings.infobar_show_sysfs_hdd );
|
||||||
configfile.setInt32("show_mute_icon" , g_settings.show_mute_icon);
|
configfile.setInt32("show_mute_icon" , g_settings.show_mute_icon);
|
||||||
configfile.setInt32("infobar_show_res" , g_settings.infobar_show_res );
|
configfile.setInt32("infobar_show_res" , g_settings.infobar_show_res );
|
||||||
|
@@ -73,6 +73,7 @@ struct SNeutrinoSettings
|
|||||||
int volume_pos;
|
int volume_pos;
|
||||||
int show_mute_icon;
|
int show_mute_icon;
|
||||||
int menu_pos;
|
int menu_pos;
|
||||||
|
int show_menu_hints;
|
||||||
int infobar_show_sysfs_hdd;
|
int infobar_show_sysfs_hdd;
|
||||||
int infobar_show_res;
|
int infobar_show_res;
|
||||||
int infobar_show_tuner;
|
int infobar_show_tuner;
|
||||||
|
Reference in New Issue
Block a user