diff --git a/data/locale/deutsch.locale b/data/locale/deutsch.locale index faca4e076..142e8de26 100644 --- a/data/locale/deutsch.locale +++ b/data/locale/deutsch.locale @@ -29,6 +29,7 @@ audiomenu.pref_subs_head Untertitelwahl audiomenu.pref_subs Sprache audiomenu.spdif_dd DolbyDigital über S/PDIF audiomenu.stereo stereo +audiomenu.volume_step Lautstärke Schrittweite audioplayer.add Hinzufügen audioplayer.add_ic Icecast audioplayer.add_loc Lokale Radioliste diff --git a/data/locale/english.locale b/data/locale/english.locale index 3f9514b09..f8c06a0df 100644 --- a/data/locale/english.locale +++ b/data/locale/english.locale @@ -147,6 +147,7 @@ audiomenu.pref_lang_head Audio/EPG language preferences audiomenu.pref_lang Prefered language audiomenu.pref_subs_head Subtitle language preferences audiomenu.pref_subs Prefered subtitle language +audiomenu.volume_step Volume step audioplayer.add Add audioplayer.artist_title Artist, Title audioplayer.building_search_index building search index diff --git a/src/neutrino.cpp b/src/neutrino.cpp index cbb0a6f87..9eecc5726 100644 --- a/src/neutrino.cpp +++ b/src/neutrino.cpp @@ -426,6 +426,7 @@ int CNeutrinoApp::loadSetup(const char * fname) g_settings.video_Format = configfile.getInt32("video_Format", DISPLAY_AR_16_9); g_settings.video_43mode = configfile.getInt32("video_43mode", DISPLAY_AR_MODE_LETTERBOX); g_settings.current_volume = configfile.getInt32("current_volume", 50); + g_settings.current_volume_step = configfile.getInt32("current_volume_step", 2); g_settings.channel_mode = configfile.getInt32("channel_mode", LIST_MODE_PROV); g_settings.channel_mode_radio = configfile.getInt32("channel_mode_radio", LIST_MODE_PROV); @@ -985,6 +986,7 @@ void CNeutrinoApp::saveSetup(const char * fname) configfile.setInt32( "hdmi_cec_standby", g_settings.hdmi_cec_standby ); configfile.setInt32( "current_volume", g_settings.current_volume ); + configfile.setInt32( "current_volume_step", g_settings.current_volume_step ); configfile.setInt32( "channel_mode", g_settings.channel_mode ); configfile.setInt32( "channel_mode_radio", g_settings.channel_mode_radio ); @@ -3718,14 +3720,14 @@ printf("CNeutrinoApp::setVolume dx %d dy %d\n", dx, dy); do { if (msg <= CRCInput::RC_MaxRC) { if (msg == CRCInput::RC_plus || msg == CRCInput::RC_right) { //FIXME - if (g_settings.current_volume < 100 - 2) - g_settings.current_volume += 2; + if (g_settings.current_volume < 100 - g_settings.current_volume_step) + g_settings.current_volume += g_settings.current_volume_step; else g_settings.current_volume = 100; } else if (msg == CRCInput::RC_minus || msg == CRCInput::RC_left) { //FIXME - if (g_settings.current_volume > 2) - g_settings.current_volume -= 2; + if (g_settings.current_volume > g_settings.current_volume_step) + g_settings.current_volume -= g_settings.current_volume_step; else g_settings.current_volume = 0; } diff --git a/src/neutrino_menue.cpp b/src/neutrino_menue.cpp index e63255d53..7d425b1f1 100644 --- a/src/neutrino_menue.cpp +++ b/src/neutrino_menue.cpp @@ -1461,6 +1461,7 @@ void CNeutrinoApp::InitAudioSettings(CMenuWidget &audioSettings, CAudioSetupNoti audioSettings.addItem(new CMenuOptionChooser(LOCALE_SRS_ALGO, &g_settings.srs_algo, AUDIOMENU_SRS_OPTIONS, AUDIOMENU_SRS_OPTION_COUNT, true, audioSetupNotifier)); audioSettings.addItem(new CMenuOptionChooser(LOCALE_SRS_NMGR, &g_settings.srs_nmgr_enable, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true, audioSetupNotifier)); audioSettings.addItem(new CMenuOptionNumberChooser(LOCALE_SRS_VOLUME, &g_settings.srs_ref_volume, true, 1, 100, audioSetupNotifier)); + audioSettings.addItem(new CMenuOptionNumberChooser(LOCALE_AUDIOMENU_VOLUME_STEP, (int *)&g_settings.current_volume_step, true, 0, 100, NULL)); //audioSettings.addItem(new CMenuSeparator(CMenuSeparator::LINE | CMenuSeparator::STRING, LOCALE_AUDIOMENU_PREF_LANG_HEAD)); audioSettings.addItem(new CMenuSeparator(CMenuSeparator::LINE)); diff --git a/src/system/locals.h b/src/system/locals.h index a12fbf73e..e6f142d9a 100644 --- a/src/system/locals.h +++ b/src/system/locals.h @@ -153,6 +153,7 @@ typedef enum { LOCALE_AUDIOMENU_PREF_LANG, LOCALE_AUDIOMENU_PREF_SUBS_HEAD, LOCALE_AUDIOMENU_PREF_SUBS, + LOCALE_AUDIOMENU_VOLUME_STEP, LOCALE_AUDIOPLAYER_ADD, LOCALE_AUDIOPLAYER_ADD_IC, LOCALE_AUDIOPLAYER_ADD_LOC, diff --git a/src/system/locals_intern.h b/src/system/locals_intern.h index 18f424d79..990fd5cd7 100644 --- a/src/system/locals_intern.h +++ b/src/system/locals_intern.h @@ -153,6 +153,7 @@ const char *locale_real_names[] = { "audiomenu.pref_lang", "audiomenu.pref_subs_head", "audiomenu.pref_subs", + "audiomenu.volume_step", "audioplayer.add", "audioplayer.add_ic", "audioplayer.add_loc", diff --git a/src/system/settings.h b/src/system/settings.h index c4c58fad2..efe1e3be6 100644 --- a/src/system/settings.h +++ b/src/system/settings.h @@ -49,6 +49,7 @@ struct SNeutrinoSettings int analog_mode2; int video_43mode; char current_volume; + int current_volume_step; int channel_mode; int channel_mode_radio;