i have a application in this app i have a video player. when i press "next" button i also pausing video. code is below:
onPress={() =>
{
this.setState({ isPaused: true }, () => {
this.props.navigation.navigate('nextScreen')
});
}}
but when i press next button first time it pauses video and move to nextScreen but if i come back to video player screen and play video again and again press next button nextScreen loads but video is not pausing this time. here is my video player
<Video
onEnd={this.onEnd}
controls={true}
onLoad={this.onLoad}
onLoadStart={this.onLoadStart}
onProgress={this.onProgress}
ref={videoPlayer => (this.videoPlayer = videoPlayer)}
resizeMode={this.screenType}
onFullScreen={this.isFullScreen}
source={require('../Images/Video.mp4')}
style={{height:'56%', width:'100%', marginTop: 50 }}
volume={10}
paused={this.state.isPaused}
/>