Fix ab1a4c6c: Changing baseset/playlist while shuffle is on does not change song. (#11510)

The change-playlist function relied on toggling shuffle to restart playing which is no longer the case, so always handle it when changing playlist instead.
This commit is contained in:
Peter Nelson 2023-11-28 17:44:31 +00:00 committed by GitHub
parent e3924f3231
commit 519fe33175
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 6 deletions

View File

@ -156,12 +156,8 @@ void MusicSystem::ChangePlaylist(PlaylistChoices pl)
this->selected_playlist = pl;
this->playlist_position = 0;
if (_settings_client.music.shuffle) {
this->Shuffle();
/* Shuffle() will also Play() if necessary, only start once */
} else if (_settings_client.music.playing) {
this->Play();
}
if (_settings_client.music.shuffle) this->Shuffle();
if (_settings_client.music.playing) this->Play();
}
InvalidateWindowData(WC_MUSIC_TRACK_SELECTION, 0);