Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix paused prop doesn't work when init the Video #625

Closed
wants to merge 1 commit into from

Conversation

Symous
Copy link

@Symous Symous commented May 19, 2017

It caused by onResume life cycle method. when the first time to run onResume, the mActiveStatePauseStatus always be false, so it always play the video.

now we can use paused prop to control the video playing status.

It caused by onResume life cycle method.
@vomchik
Copy link

vomchik commented Jun 1, 2017

Very important fix :)
Thanks!

Copy link

@krizpoon krizpoon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one problem in this approach: if the video is playing and onHostPause is triggered, the video would not resume when onHostResume because onHostPause will invoke setPausedModifier(true);

@abhideepmallick
Copy link

Life saver, please merge this!

@krizpoon
Copy link

I think the latest master branch already fixed this

@luisfuertes
Copy link

luisfuertes commented Jul 20, 2017

In master package.json file, version is 1.1.0, but on npm install react-native-video@1.1.0:
captura de pantalla 2017-07-20 a las 12 53 27

@SharanyaRao91
Copy link

Manually added "mActiveStatePauseStatus = paused;" to my ReactVideoView.java file. But videos continue to autoplay. Here is what I have (RN - 0.44; react-native-video - 2.0.0) -
rate={0} //paused
paused={true}
volume={1}
muted={false}
playInBackground={false} // Audio continues to play when app entering background.
playWhenInactive={false}
ignoreSilentSwitch={"obey"}
resizeMode="cover"
onError={e => console.log(e)}
onLoad={load => console.log(load)}
repeat={false}

@afilp
Copy link

afilp commented Feb 14, 2018

Does anybody maintain this library anymore? We need these PRs merged, if possible. Thanks!

@cobarx
Copy link
Contributor

cobarx commented Jun 23, 2018

I reworked this in #1082 so we don't even need the active status paused field. In my testing everything is working properly now. Will be released in 3.0.

@cobarx cobarx closed this Jun 23, 2018
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.

8 participants