From f0a3988066f72a28bb44520af072f18d91d77dde Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Thu, 7 Mar 2019 17:06:00 +0100 Subject: Add to playlist dropdown --- client/src/assets/player/webtorrent/webtorrent-plugin.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'client/src/assets/player/webtorrent') diff --git a/client/src/assets/player/webtorrent/webtorrent-plugin.ts b/client/src/assets/player/webtorrent/webtorrent-plugin.ts index c69bf31fa..c7182acc9 100644 --- a/client/src/assets/player/webtorrent/webtorrent-plugin.ts +++ b/client/src/assets/player/webtorrent/webtorrent-plugin.ts @@ -6,7 +6,7 @@ import * as WebTorrent from 'webtorrent' import { VideoFile } from '../../../../../shared/models/videos/video.model' import { renderVideo } from './video-renderer' import { LoadedQualityData, PlayerNetworkInfo, VideoJSComponentInterface, WebtorrentPluginOptions } from '../peertube-videojs-typings' -import { getRtcConfig, videoFileMaxByResolution, videoFileMinByResolution } from '../utils' +import { getRtcConfig, timeToInt, videoFileMaxByResolution, videoFileMinByResolution } from '../utils' import { PeertubeChunkStore } from './peertube-chunk-store' import { getAverageBandwidthInStore, @@ -73,6 +73,8 @@ class WebTorrentPlugin extends Plugin { constructor (player: videojs.Player, options: WebtorrentPluginOptions) { super(player, options) + this.startTime = timeToInt(options.startTime) + // Disable auto play on iOS this.autoplay = options.autoplay && this.isIOS() === false this.playerRefusedP2P = !getStoredWebTorrentEnabled() -- cgit v1.2.3