Skip to content

Commit 2e35d9b

Browse files
committed
Do not shuffle mixed playing if not allowed
1 parent 762828d commit 2e35d9b

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

core/src/main/java/xyz/gianlu/librespot/player/StateWrapper.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -880,8 +880,9 @@ synchronized void initializeStart() throws IOException, MercuryClient.MercuryExc
880880
if (!PlayableId.canPlaySomething(tracks))
881881
throw AbsSpotifyContext.UnsupportedContextException.cannotPlayAnything();
882882

883-
if (context.isFinite() && isShufflingContext())
884-
shuffleEntirely();
883+
boolean transformingShuffle = Boolean.parseBoolean(state.getContextMetadataOrDefault("transforming.shuffle", "true"));
884+
if (context.isFinite() && isShufflingContext() && transformingShuffle) shuffleEntirely();
885+
else state.getOptionsBuilder().setShufflingContext(false); // Must do this directly!
885886

886887
setCurrentTrackIndex(0);
887888
}

0 commit comments

Comments
 (0)