From 4de5d09382f126af392c09462c691a74e25e782c Mon Sep 17 00:00:00 2001 From: Roy Olav Purser Date: Thu, 20 May 2021 15:33:35 +0200 Subject: [PATCH] try to disable volume control --- frontend/script.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/frontend/script.js b/frontend/script.js index 1f9d7d1..a7f40cb 100644 --- a/frontend/script.js +++ b/frontend/script.js @@ -40,9 +40,6 @@ let Button = videojs.getComponent("Button"); let cbutton = {}; cbutton.clickHandler = (ev) => { - if(player.volume() > 0.5) { - player.volume(0.1); - } player.trigger("chromecastRequested"); } let button = new Button(player, cbutton); @@ -51,6 +48,8 @@ button.addClass("vjs-control"); button.addClass("vjs-button"); button.addClass("vjs-big-chromecast"); + + player.chromecastSessionManager.remotePlayer.canControlVolume = false; player.one("chromecastDevicesAvailable", () => { player.addChild(button); player.one("play", () => {