mirror of
https://github.com/TeamNewPipe/NewPipe.git
synced 2024-11-25 12:32:31 +01:00
Fix first item played in playlists when switching player type or resolution
The issue was caused by an ExoPlayer change, which when setting a media source, resets the current playback position and the current window index by default. Also set player recovery in more places to fix playback position not propely set in some cases after a player type switch.
This commit is contained in:
parent
1531a5112c
commit
ea07d7751b
@ -2048,7 +2048,7 @@ public final class Player implements
|
|||||||
if (currentState == STATE_BLOCKED) {
|
if (currentState == STATE_BLOCKED) {
|
||||||
changeState(STATE_BUFFERING);
|
changeState(STATE_BUFFERING);
|
||||||
}
|
}
|
||||||
simpleExoPlayer.setMediaSource(mediaSource);
|
simpleExoPlayer.setMediaSource(mediaSource, false);
|
||||||
simpleExoPlayer.prepare();
|
simpleExoPlayer.prepare();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user