aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/assets/player/peertube-videojs-plugin.ts
diff options
context:
space:
mode:
authorbuoyantair <buoyantair@protonmail.com>2018-11-18 21:55:52 +0530
committerbuoyantair <buoyantair@protonmail.com>2018-11-18 21:55:52 +0530
commitb9f234371bfaf0d9cfa81e02fcea92cac1f9ae13 (patch)
treedcdf451ac431ec7953bee58e814f642d1c370d1b /client/src/assets/player/peertube-videojs-plugin.ts
parent92e07c3b5d9dbf2febedb1b5b87ec676eb6d1ac8 (diff)
parent9d0b856e930ee1c676d16a56408a3e4a18f8f978 (diff)
downloadPeerTube-b9f234371bfaf0d9cfa81e02fcea92cac1f9ae13.tar.gz
PeerTube-b9f234371bfaf0d9cfa81e02fcea92cac1f9ae13.tar.zst
PeerTube-b9f234371bfaf0d9cfa81e02fcea92cac1f9ae13.zip
Merge branch 'develop' of https://github.com/Chocobozzz/PeerTube into move-utils-to-shared
Diffstat (limited to 'client/src/assets/player/peertube-videojs-plugin.ts')
-rw-r--r--client/src/assets/player/peertube-videojs-plugin.ts5
1 files changed, 5 insertions, 0 deletions
diff --git a/client/src/assets/player/peertube-videojs-plugin.ts b/client/src/assets/player/peertube-videojs-plugin.ts
index 40da5f1f7..4fd5a9be2 100644
--- a/client/src/assets/player/peertube-videojs-plugin.ts
+++ b/client/src/assets/player/peertube-videojs-plugin.ts
@@ -111,6 +111,8 @@ class PeerTubePlugin extends Plugin {
111 const muted = getStoredMute() 111 const muted = getStoredMute()
112 if (muted !== undefined) this.player.muted(muted) 112 if (muted !== undefined) this.player.muted(muted)
113 113
114 this.player.duration(options.videoDuration)
115
114 this.initializePlayer() 116 this.initializePlayer()
115 this.runTorrentInfoScheduler() 117 this.runTorrentInfoScheduler()
116 this.runViewAdd() 118 this.runViewAdd()
@@ -302,6 +304,9 @@ class PeerTubePlugin extends Plugin {
302 304
303 this.flushVideoFile(previousVideoFile) 305 this.flushVideoFile(previousVideoFile)
304 306
307 // Update progress bar (just for the UI), do not wait rendering
308 if (options.seek) this.player.currentTime(options.seek)
309
305 const renderVideoOptions = { autoplay: false, controls: true } 310 const renderVideoOptions = { autoplay: false, controls: true }
306 renderVideo(torrent.files[ 0 ], this.playerElement, renderVideoOptions, (err, renderer) => { 311 renderVideo(torrent.files[ 0 ], this.playerElement, renderVideoOptions, (err, renderer) => {
307 this.renderer = renderer 312 this.renderer = renderer