From 5f85f8aa1c7a732a44a873de5f8f7aa41953a8f8 Mon Sep 17 00:00:00 2001 From: Rigel Kent Date: Mon, 18 Nov 2019 09:55:23 +0100 Subject: Video-watch hooks modifications for videojs --- client/src/app/videos/+video-watch/video-watch.component.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'client/src/app/videos') diff --git a/client/src/app/videos/+video-watch/video-watch.component.ts b/client/src/app/videos/+video-watch/video-watch.component.ts index 1e7991738..af4afd456 100644 --- a/client/src/app/videos/+video-watch/video-watch.component.ts +++ b/client/src/app/videos/+video-watch/video-watch.component.ts @@ -20,6 +20,7 @@ import { environment } from '../../../environments/environment' import { VideoCaptionService } from '@app/shared/video-caption' import { MarkdownService } from '@app/shared/renderer' import { + videojs, CustomizationOptions, P2PMediaLoaderOptions, PeertubePlayerManager, @@ -500,6 +501,8 @@ export class VideoWatchComponent implements OnInit, OnDestroy { this.player.on('theaterChange', (_: any, enabled: boolean) => { this.zone.run(() => this.theaterEnabled = enabled) }) + + this.hooks.runAction('action:video-watch.player.loaded', 'video-watch', { player: this.player }) }) this.setVideoDescriptionHTML() @@ -508,7 +511,7 @@ export class VideoWatchComponent implements OnInit, OnDestroy { this.setOpenGraphTags() this.checkUserRating() - this.hooks.runAction('action:video-watch.video.loaded', 'video-watch') + this.hooks.runAction('action:video-watch.video.loaded', 'video-watch', { videojs }) } private autoplayNext () { -- cgit v1.2.3