Skip to content

Fire onSeek after seek completes on Android, document onSeek#1351

Merged
cobarx merged 2 commits intomasterfrom
bugfix/android-seek-event
Nov 28, 2018
Merged

Fire onSeek after seek completes on Android, document onSeek#1351
cobarx merged 2 commits intomasterfrom
bugfix/android-seek-event

Conversation

@cobarx
Copy link
Contributor

@cobarx cobarx commented Nov 28, 2018

The implementation for onSeek was incorrect on both Android MediaPlayer & ExoPlayer. The code would generate a seekEvent before performing the seek, which is pretty much useless. I've updated the code to wait until we receive a seek complete event from the player and then generate the event. That way we can get the actual position post-seek. This matches the behavior for iOS.

This event wasn't documented, so I've added that as well.

@cobarx cobarx merged commit e1c1eb6 into master Nov 28, 2018
@cobarx cobarx deleted the bugfix/android-seek-event branch November 28, 2018 03:52
@dylancom
Copy link

Thanks!

beauner69 pushed a commit to beauner69/react-native-video that referenced this pull request Oct 10, 2019
…ugfix/android-seek-event

Fire onSeek after seek completes on Android, document onSeek

(rebased from commit e1c1eb6)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants