Fix continue watching advancing to the next episode before finishing the current one - #3211
Closed
mehdigm4life wants to merge 1 commit into
Closed
mehdigm4life wants to merge 1 commit into
mehdigm4life wants to merge 1 commit into
Conversation
Author
Collaborator
|
It was intentionally designed to go to the next episode at 90% watch time. This is a counterintuitive quality of life feature which is designed to let users continue watching without having to watch the outro/credits of the previous episode. |
Author
|
@fire-light42 and streamRuby extractor PR ? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue
When exiting the internal player during the last minutes of an episode — before it actually finished — the Continue Watching row would already show the next episode from the start, even though the current episode was never completed.
The reason: resume progress was saved on a milestone, and
setViewPosAndResumeimmediately switched the "continue watching" entry to the next episode once progress reached 90% of the current one.Fix
The next episode only becomes the resume target once the current episode has actually finished playing:
DataStoreHelper.setViewPosAndResumenow takes acompletedflag. Unless the video reached its end, the resume entry stays on the current episode (at the position where you left).GeneratorPlayer.nextEpisode()before advancing to the next episode, andonVideoEnded()callback for when autoplay is disabled and the player stays on the end screen.PlayerView.onVideoEnded()so host fragments are notified when playback reaches the end.Behavior after the fix
Verified by compiling with
:app:compileStableDebugKotlin. No settings or UI changes.