summaryrefslogtreecommitdiff
path: root/priv/static/room/main.js
diff options
context:
space:
mode:
Diffstat (limited to 'priv/static/room/main.js')
-rw-r--r--priv/static/room/main.js45
1 files changed, 1 insertions, 44 deletions
diff --git a/priv/static/room/main.js b/priv/static/room/main.js
index 8e46f66..b82c14c 100644
--- a/priv/static/room/main.js
+++ b/priv/static/room/main.js
@@ -61,19 +61,7 @@
}
{
- let customIconPosition = 1;
const Button = videojs.getComponent("Button");
- if (HOME_BUTTON_URL !== null) {
- const homeButton = new Button(player, {
- clickHandler: (_) => {
- location = HOME_BUTTON_URL;
- },
- });
- homeButton.addClass("icon-home");
- homeButton.controlText("Return Home");
- player.controlBar.addChild(homeButton, {}, customIconPosition++);
- }
-
const stateButton = new Button(player, {
clickHandler: (_) => {
const stateButtonEl = stateButton.el();
@@ -83,38 +71,7 @@
stateButton.el().setAttribute("data-text", STATE_ELEMENT_INITIAL_TEXT);
stateButton.addClass("icon-users state-element");
stateButton.controlText("Viewers");
- player.controlBar.addChild(stateButton, {}, customIconPosition++);
-
- if (SHOW_SNAP_BUTTON) {
- const SNAP_NEXT_L = "icon-left";
- const SNAP_NEXT_R = "icon-right";
- const SNAP_NEXT_LR = "icon-left-right";
- const SNAP_TITLE_L = "Snap Video To Left";
- const SNAP_TITLE_R = "Snap Video To Right";
- const SNAP_TITLE_LR = "Snap Video To Center";
- const snapButton = new Button(player, {
- clickHandler: (_) => {
- const snapButtonEl = snapButton.el();
- if (snapButtonEl.classList.contains(SNAP_NEXT_L)) {
- snapButtonEl.classList.remove(SNAP_NEXT_L);
- snapButtonEl.classList.add(SNAP_NEXT_R);
- snapButtonEl.title = SNAP_TITLE_R;
- } else if (snapButtonEl.classList.contains(SNAP_NEXT_R)) {
- snapButtonEl.classList.remove(SNAP_NEXT_R);
- snapButtonEl.classList.add(SNAP_NEXT_LR);
- snapButtonEl.title = SNAP_TITLE_LR;
- } else {
- snapButtonEl.classList.remove(SNAP_NEXT_LR);
- snapButtonEl.classList.add(SNAP_NEXT_L);
- snapButtonEl.title = SNAP_TITLE_L;
- }
- },
- });
- snapButton.el().id = "snap-button";
- snapButton.addClass(SNAP_NEXT_L);
- snapButton.controlText(SNAP_TITLE_L);
- player.controlBar.addChild(snapButton, {}, customIconPosition++);
- }
+ player.controlBar.addChild(stateButton, {}, 1);
}
const updatePlaybackState = (latestReceivedState, nowMilliseconds) => {