From 4b711c2f72608441f1ef44db584eccc9ca823ea1 Mon Sep 17 00:00:00 2001 From: Magnus Holmgren Date: Sat, 24 Sep 2005 15:22:48 +0000 Subject: Iriver: Added new ReplayGain type: track gain if shuffle mode is active, album gain otherwise. Properly apply ReplayGain settings on config file load. Bumped config version, so save your settings. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7558 a1c6a512-1295-4272-9138-f99709370657 --- apps/settings_menu.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'apps/settings_menu.c') diff --git a/apps/settings_menu.c b/apps/settings_menu.c index 1bbb09d..59c8005 100644 --- a/apps/settings_menu.c +++ b/apps/settings_menu.c @@ -1184,11 +1184,13 @@ static bool replaygain(void) static bool replaygain_mode(void) { - bool result = set_bool_options(str(LANG_REPLAYGAIN_MODE), - &global_settings.replaygain_track, - STR(LANG_TRACK_GAIN), - STR(LANG_ALBUM_GAIN), - NULL); + static const struct opt_items names[] = { + { STR(LANG_TRACK_GAIN) }, + { STR(LANG_ALBUM_GAIN) }, + { STR(LANG_SHUFFLE_GAIN) }, + }; + bool result = set_option(str(LANG_REPLAYGAIN_MODE), + &global_settings.replaygain_type, INT, names, 3, NULL); dsp_set_replaygain(true); return result; @@ -1294,6 +1296,8 @@ static bool playback_settings_menu(void) if ((old_shuffle != global_settings.playlist_shuffle) && (audio_status() & AUDIO_STATUS_PLAY)) { + dsp_set_replaygain(true); + if (global_settings.playlist_shuffle) { playlist_randomise(NULL, current_tick, true); -- cgit v1.1