mirror of
https://github.com/samsonjs/media.git
synced 2026-04-02 10:45:51 +00:00
Fix seeking before a source is set.
Before this change, calling seekTo then setPlayWhenReady would cause the player throw an error, due to using the sample source provider before it's set. Transition to the buffering state in seekToInternal only if we have a sample source provider. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=126804528
This commit is contained in:
parent
e02ca775f3
commit
42d78b3559
1 changed files with 1 additions and 1 deletions
|
|
@ -468,7 +468,6 @@ import java.util.ArrayList;
|
|||
return;
|
||||
}
|
||||
|
||||
setState(ExoPlayer.STATE_BUFFERING);
|
||||
stopRenderers();
|
||||
rebuffering = false;
|
||||
|
||||
|
|
@ -483,6 +482,7 @@ import java.util.ArrayList;
|
|||
|
||||
updatePlaybackPositions();
|
||||
if (sampleSourceProvider != null) {
|
||||
setState(ExoPlayer.STATE_BUFFERING);
|
||||
handler.sendEmptyMessage(MSG_DO_SOME_WORK);
|
||||
}
|
||||
} finally {
|
||||
|
|
|
|||
Loading…
Reference in a new issue