Resume from playback position by default when media source changes

Issue:#2369

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=145982198
This commit is contained in:
aquilescanta 2017-01-30 05:38:43 -08:00 committed by Oliver Woodman
parent c49d142981
commit 9a90795041

View File

@ -1215,7 +1215,7 @@ import java.io.IOException;
long newLoadingPeriodStartPositionUs; long newLoadingPeriodStartPositionUs;
if (loadingPeriodHolder == null) { if (loadingPeriodHolder == null) {
newLoadingPeriodStartPositionUs = playbackInfo.startPositionUs; newLoadingPeriodStartPositionUs = playbackInfo.positionUs;
} else { } else {
int newLoadingWindowIndex = timeline.getPeriod(newLoadingPeriodIndex, period).windowIndex; int newLoadingWindowIndex = timeline.getPeriod(newLoadingPeriodIndex, period).windowIndex;
if (newLoadingPeriodIndex if (newLoadingPeriodIndex