Commit fb2ef107 authored by Max Kellermann's avatar Max Kellermann

playlist: check if repeat mode changes

Add a "changed" check to setPlaylistRepeatStatus(): when the new repeat mode is the same as the old one, don't do anything at all. No more checks, no "idle" event.
parent 9cad3420
......@@ -828,8 +828,11 @@ bool getPlaylistRandomStatus(void)
void setPlaylistRepeatStatus(bool status)
{
if (status == playlist.queue.repeat)
return;
if (playlist_state == PLAYLIST_STATE_PLAY &&
playlist.queue.repeat && !status && playlist.queued == 0)
playlist.queue.repeat && playlist.queued == 0)
clearPlayerQueue();
playlist.queue.repeat = status;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment