Revert "Shuffle all songs instead of from the current to the end"

This reverts commit 316a3d51ee.
This commit is contained in:
Jonas Kvinge 2021-05-04 23:16:18 +02:00
parent 316a3d51ee
commit fb7b3b0295
1 changed files with 3 additions and 0 deletions

View File

@ -1875,8 +1875,11 @@ void Playlist::ReshuffleIndices() {
return;
}
// If the user is already playing a song, advance the begin iterator to only shuffle items that haven't been played yet.
QList<int>::iterator begin = virtual_items_.begin();
QList<int>::iterator end = virtual_items_.end();
if (current_virtual_index_ != -1)
std::advance(begin, current_virtual_index_ + 1);
std::random_device rd;
std::mt19937 g(rd());