Fix some typos and add docs for controls & onEnd
This commit is contained in:
parent
fae09eb4cf
commit
53ed7e168e
23
README.md
23
README.md
@ -233,7 +233,6 @@ import Video from 'react-native-video';
|
|||||||
this.player = ref
|
this.player = ref
|
||||||
}} // Store reference
|
}} // Store reference
|
||||||
onBuffer={this.onBuffer} // Callback when remote video is buffering
|
onBuffer={this.onBuffer} // Callback when remote video is buffering
|
||||||
onEnd={this.onEnd} // Callback when playback finishes
|
|
||||||
onError={this.videoError} // Callback when video cannot be loaded
|
onError={this.videoError} // Callback when video cannot be loaded
|
||||||
style={styles.backgroundVideo} />
|
style={styles.backgroundVideo} />
|
||||||
|
|
||||||
@ -253,6 +252,7 @@ var styles = StyleSheet.create({
|
|||||||
* [allowsExternalPlayback](#allowsexternalplayback)
|
* [allowsExternalPlayback](#allowsexternalplayback)
|
||||||
* [audioOnly](#audioonly)
|
* [audioOnly](#audioonly)
|
||||||
* [bufferConfig](#bufferconfig)
|
* [bufferConfig](#bufferconfig)
|
||||||
|
* [controls](#controls)
|
||||||
* [ignoreSilentSwitch](#ignoresilentswitch)
|
* [ignoreSilentSwitch](#ignoresilentswitch)
|
||||||
* [muted](#muted)
|
* [muted](#muted)
|
||||||
* [paused](#paused)
|
* [paused](#paused)
|
||||||
@ -274,6 +274,7 @@ var styles = StyleSheet.create({
|
|||||||
|
|
||||||
### Event props
|
### Event props
|
||||||
* [onAudioBecomingNoisy](#onaudiobecomingnoisy)
|
* [onAudioBecomingNoisy](#onaudiobecomingnoisy)
|
||||||
|
* [onEnd](#onend)
|
||||||
* [onFullscreenPlayerWillPresent](#onfullscreenplayerwillpresent)
|
* [onFullscreenPlayerWillPresent](#onfullscreenplayerwillpresent)
|
||||||
* [onFullscreenPlayerDidPresent](#onfullscreenplayerdidpresent)
|
* [onFullscreenPlayerDidPresent](#onfullscreenplayerdidpresent)
|
||||||
* [onFullscreenPlayerWillDismiss](#onfullscreenplayerwilldismiss)
|
* [onFullscreenPlayerWillDismiss](#onfullscreenplayerwilldismiss)
|
||||||
@ -330,6 +331,15 @@ bufferConfig={{
|
|||||||
|
|
||||||
Platforms: Android ExoPlayer
|
Platforms: Android ExoPlayer
|
||||||
|
|
||||||
|
#### controls
|
||||||
|
Determines whether to show player controls.
|
||||||
|
* ** false (default)** - Don't show player controls
|
||||||
|
* **true** - Show player controls
|
||||||
|
|
||||||
|
Note on iOS, controls are always shown when in fullscreen mode.
|
||||||
|
|
||||||
|
Platforms: DOM, iOS
|
||||||
|
|
||||||
#### ignoreSilentSwitch
|
#### ignoreSilentSwitch
|
||||||
Controls the iOS silent switch behavior
|
Controls the iOS silent switch behavior
|
||||||
* **"inherit" (default)** - Use the default AVPlayer behavior
|
* **"inherit" (default)** - Use the default AVPlayer behavior
|
||||||
@ -611,6 +621,13 @@ Payload: none
|
|||||||
|
|
||||||
Platforms: Android ExoPlayer, iOS
|
Platforms: Android ExoPlayer, iOS
|
||||||
|
|
||||||
|
#### onEnd
|
||||||
|
Callback function that is called when the player reaches the end of the media.
|
||||||
|
|
||||||
|
Payload: none
|
||||||
|
|
||||||
|
Platforms: all
|
||||||
|
|
||||||
#### onFullscreenPlayerWillPresent
|
#### onFullscreenPlayerWillPresent
|
||||||
Callback function that is called when the player is about to enter fullscreen mode.
|
Callback function that is called when the player is about to enter fullscreen mode.
|
||||||
|
|
||||||
@ -722,6 +739,8 @@ Example:
|
|||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Platforms: all
|
||||||
|
|
||||||
#### onTimedMetadata
|
#### onTimedMetadata
|
||||||
Callback function that is called when timed metadata becomes available
|
Callback function that is called when timed metadata becomes available
|
||||||
|
|
||||||
@ -767,7 +786,7 @@ this.player.dismissFullscreenPlayer();
|
|||||||
|
|
||||||
Platforms: Android ExoPlayer, Android MediaPlayer, iOS
|
Platforms: Android ExoPlayer, Android MediaPlayer, iOS
|
||||||
|
|
||||||
#### FullscreenPlayer
|
#### presentFullscreenPlayer
|
||||||
`presentFullscreenPlayer()`
|
`presentFullscreenPlayer()`
|
||||||
|
|
||||||
Put the player in fullscreen mode.
|
Put the player in fullscreen mode.
|
||||||
|
Loading…
Reference in New Issue
Block a user