aboutsummaryrefslogtreecommitdiffstats
path: root/src/replay_gain_config.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/replay_gain_config.c')
-rw-r--r--src/replay_gain_config.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/replay_gain_config.c b/src/replay_gain_config.c
index 3eae9d960..2ef39a4b7 100644
--- a/src/replay_gain_config.c
+++ b/src/replay_gain_config.c
@@ -19,6 +19,7 @@
#include "config.h"
#include "replay_gain_config.h"
+#include "playlist.h"
#include "conf.h"
#include "idle.h"
@@ -129,3 +130,15 @@ void replay_gain_global_init(void)
replay_gain_missing_preamp = pow(10, f / 20.0);
}
}
+
+enum replay_gain_mode replay_gain_get_real_mode(void)
+{
+ enum replay_gain_mode rgm;
+
+ rgm = replay_gain_mode;
+
+ if (rgm == REPLAY_GAIN_AUTO)
+ rgm = g_playlist.queue.random ? REPLAY_GAIN_TRACK : REPLAY_GAIN_ALBUM;
+
+ return rgm;
+}