Skip to content

Commit

Permalink
Fix skipping to end of video reports wrong end time
Browse files Browse the repository at this point in the history
  • Loading branch information
nielsvanvelzen committed Nov 12, 2024
1 parent 87e4e7e commit 169d094
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -888,8 +888,10 @@ public void seek(long pos, boolean skipToNext) {
if (skipToNext && pos >= (getDuration() - 100)) {
// Since we've skipped ahead, set the current position so the PlaybackStopInfo will report the correct end time
mCurrentPosition = getDuration();
// Make sure we also set the seek position so it won't get overwritten in refreshCurrentPosition()
// Make sure we also set the seek positions so mCurrentPosition won't get overwritten in refreshCurrentPosition()
currentSkipPos = mCurrentPosition;
mSeekPosition = mCurrentPosition;
// Finalize item playback
itemComplete();
return;
}
Expand Down

0 comments on commit 169d094

Please sign in to comment.