Don't skip around when doing "Play Next" while music is playing

This commit is contained in:
tzugen 2023-08-03 14:28:22 +02:00
parent a0b9e738a5
commit e9fdbd924b
No known key found for this signature in database
GPG Key ID: 61E9C34BC10EC930
2 changed files with 2 additions and 2 deletions

View File

@ -460,7 +460,7 @@ class MediaPlayerManager(
// We can't just use play(0,0) then all random playlists will start with the first track. // We can't just use play(0,0) then all random playlists will start with the first track.
// Additionally the shuffle order becomes clear on after some time, so we need to wait for // Additionally the shuffle order becomes clear on after some time, so we need to wait for
// the right event, and can start playback only then. // the right event, and can start playback only then.
if (autoPlay) { if (autoPlay && controller?.isPlaying != true) {
if (isShufflePlayEnabled) { if (isShufflePlayEnabled) {
deferredPlay = { deferredPlay = {
val start = controller?.currentTimeline val start = controller?.currentTimeline

View File

@ -169,7 +169,7 @@ class DownloadHandler(
) )
if (Settings.shouldTransitionOnPlayback && if (Settings.shouldTransitionOnPlayback &&
(insertionMode == MediaPlayerManager.InsertionMode.CLEAR || autoPlay) insertionMode == MediaPlayerManager.InsertionMode.CLEAR
) { ) {
fragment.findNavController().popBackStack(R.id.playerFragment, true) fragment.findNavController().popBackStack(R.id.playerFragment, true)
fragment.findNavController().navigate(R.id.playerFragment) fragment.findNavController().navigate(R.id.playerFragment)