From 8db69414e6c336a6c6057058d74ddd71d42397a9 Mon Sep 17 00:00:00 2001 From: Issac Gerges Date: Wed, 5 Aug 2015 16:56:08 -0500 Subject: [PATCH] Add the ability to configure a 'minimal' display mode that hides all non-call features --- index.html | 2 +- interface_config.js | 1 + modules/UI/toolbars/Toolbar.js | 13 +++++++++++++ 3 files changed, 15 insertions(+), 1 deletion(-) diff --git a/index.html b/index.html index 123d04906..df0e9058b 100644 --- a/index.html +++ b/index.html @@ -170,7 +170,7 @@
- + diff --git a/interface_config.js b/interface_config.js index e664812ee..edbf0617d 100644 --- a/interface_config.js +++ b/interface_config.js @@ -5,6 +5,7 @@ var interfaceConfig = { INITIAL_TOOLBAR_TIMEOUT: 20000, TOOLBAR_TIMEOUT: 4000, DEFAULT_REMOTE_DISPLAY_NAME: "Fellow Jitster", + TOOLBAR_DISPLAY_MODE: 'full', DEFAULT_DOMINANT_SPEAKER_DISPLAY_NAME: "speaker", DEFAULT_LOCAL_DISPLAY_NAME: "me", SHOW_JITSI_WATERMARK: true, diff --git a/modules/UI/toolbars/Toolbar.js b/modules/UI/toolbars/Toolbar.js index 6b08b0e8c..8dc7e518d 100644 --- a/modules/UI/toolbars/Toolbar.js +++ b/modules/UI/toolbars/Toolbar.js @@ -249,6 +249,19 @@ function callSipButtonClicked() { var Toolbar = (function (my) { my.init = function (ui) { + if (interfaceConfig.TOOLBAR_DISPLAY_MODE === 'minimal') { + var btnToHide = ["#toolbar_button_security", + "#toolbar_button_link", + "#chat_button", + "#prezi_button", + "#bottom_toolbar_chat", + "#bottom_toolbar_contact_list"]; + $.each(btnToHide, function (idx, btn) { + $(btn).hide(); + $(btn).next('.header_button_separator').hide(); + }); + } + for(var k in buttonHandlers) $("#" + k).click(buttonHandlers[k]); UI = ui;