Fix resume position if user seeks whilst in error state

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=146001900
This commit is contained in:
olly 2017-01-30 09:32:57 -08:00 committed by Oliver Woodman
parent 8ddfc12f05
commit 4b8a6572fd

View File

@ -425,7 +425,12 @@ public class PlayerActivity extends Activity implements OnClickListener, ExoPlay
@Override
public void onPositionDiscontinuity() {
// Do nothing.
if (playerNeedsSource) {
// This will only occur if the user has performed a seek whilst in the error state. Update the
// resume position so that if the user then retries, playback will resume from the position to
// which they seeked.
updateResumePosition();
}
}
@Override