volume control test
This commit is contained in:
parent
4de5d09382
commit
af036abf0d
@ -40,6 +40,11 @@
|
||||
let Button = videojs.getComponent("Button");
|
||||
let cbutton = {};
|
||||
cbutton.clickHandler = (ev) => {
|
||||
try {
|
||||
player.chromecastSessionManager.remotePlayer.canControlVolume = false;
|
||||
} catch(error) {
|
||||
console.log(error);
|
||||
}
|
||||
player.trigger("chromecastRequested");
|
||||
}
|
||||
let button = new Button(player, cbutton);
|
||||
@ -49,13 +54,12 @@
|
||||
button.addClass("vjs-button");
|
||||
button.addClass("vjs-big-chromecast");
|
||||
|
||||
player.chromecastSessionManager.remotePlayer.canControlVolume = false;
|
||||
player.one("chromecastDevicesAvailable", () => {
|
||||
//player.one("chromecastDevicesAvailable", () => {
|
||||
player.addChild(button);
|
||||
player.one("play", () => {
|
||||
player.removeChild(button);
|
||||
});
|
||||
});
|
||||
//});
|
||||
}
|
||||
}
|
||||
document.addEventListener("DOMContentLoaded", handleCount);
|
||||
|
Loading…
Reference in New Issue
Block a user