diff --git a/examples/basic/src/VideoPlayer.tsx b/examples/basic/src/VideoPlayer.tsx index 1caaf98a24..e437b2b19e 100644 --- a/examples/basic/src/VideoPlayer.tsx +++ b/examples/basic/src/VideoPlayer.tsx @@ -133,6 +133,11 @@ class VideoPlayer extends Component { description: 'sintel with subtitles', uri: 'https://bitmovin-a.akamaihd.net/content/sintel/hls/playlist.m3u8', }, + { + description: 'sintel starts at 20sec', + uri: 'https://bitmovin-a.akamaihd.net/content/sintel/hls/playlist.m3u8', + startPosition: 50000, + }, { description: 'BigBugBunny sideLoaded subtitles', // sideloaded subtitles wont work for streaming like HLS on ios @@ -360,7 +365,9 @@ class VideoPlayer extends Component { }; onEnd = () => { - this.channelUp(); + if (!this.state.loop) { + this.channelUp(); + } }; onPlaybackRateChange = (data: OnPlaybackRateChangeData) => { @@ -593,8 +600,8 @@ class VideoPlayer extends Component { renderTopControl() { return ( - <> - + + {this.srcList[this.state.srcListId]?.description || 'local file'} @@ -602,12 +609,12 @@ class VideoPlayer extends Component { onPress={() => { this.toggleControls(); }}> - + {this.state.showRNVControls ? 'Hide controls' : 'Show controls'} - + ); } @@ -1032,6 +1039,9 @@ const styles = StyleSheet.create({ width: 100, height: 40, }, -}); + topControlsContainer: { + paddingTop: 30, + } + }); export default VideoPlayer;