Partition: add UpdateEffectiveReplayGainMode()
Move code from replay_gain_get_real_mode().
This commit is contained in:
@@ -42,6 +42,17 @@ Partition::EmitIdle(unsigned mask)
|
||||
instance.EmitIdle(mask);
|
||||
}
|
||||
|
||||
void
|
||||
Partition::UpdateEffectiveReplayGainMode(ReplayGainMode mode)
|
||||
{
|
||||
if (mode == REPLAY_GAIN_AUTO)
|
||||
mode = playlist.queue.random
|
||||
? REPLAY_GAIN_TRACK
|
||||
: REPLAY_GAIN_ALBUM;
|
||||
|
||||
outputs.SetReplayGainMode(mode);
|
||||
}
|
||||
|
||||
#ifdef ENABLE_DATABASE
|
||||
|
||||
const Database *
|
||||
|
Reference in New Issue
Block a user