From cc58eceb49dddc81c5113751f838412754741a2a Mon Sep 17 00:00:00 2001 From: CJ <72030708+cj12312021@users.noreply.github.com> Date: Mon, 11 Mar 2024 21:33:28 -0500 Subject: [PATCH] play monitoring improvement (#4670) --- ui/v2.5/src/components/ScenePlayer/track-activity.ts | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/ui/v2.5/src/components/ScenePlayer/track-activity.ts b/ui/v2.5/src/components/ScenePlayer/track-activity.ts index 6b5cbd05107..a3846dc87d5 100644 --- a/ui/v2.5/src/components/ScenePlayer/track-activity.ts +++ b/ui/v2.5/src/components/ScenePlayer/track-activity.ts @@ -25,10 +25,18 @@ class TrackActivityPlugin extends videojs.getPlugin("plugin") { constructor(player: VideoJsPlayer) { super(player); - player.on("play", () => { + player.on("playing", () => { this.start(); }); + player.on("waiting", () => { + this.stop(); + }); + + player.on("stalled", () => { + this.stop(); + }); + player.on("pause", () => { this.stop(); });