diff --git a/index.html b/index.html
index e647cceae..725aaa65b 100644
--- a/index.html
+++ b/index.html
@@ -123,6 +123,7 @@
+
@@ -137,6 +138,7 @@
+
diff --git a/interface_config.js b/interface_config.js
index 6eeaf1725..9780d27f2 100644
--- a/interface_config.js
+++ b/interface_config.js
@@ -20,7 +20,7 @@ var interfaceConfig = {
// the toolbar buttons line is intentionally left in one line, to be able
// to easily override values or remove them using regex
MAIN_TOOLBAR_BUTTONS: ['microphone', 'camera', 'desktop', 'invite', 'hangup'], // jshint ignore:line
- TOOLBAR_BUTTONS: ['profile', 'authentication', 'microphone', 'camera', 'desktop', 'recording', 'security', 'invite', 'chat', 'etherpad', 'sharedvideo', 'fullscreen', 'sip', 'dialpad', 'settings', 'hangup', 'filmstrip', 'contacts'], // jshint ignore:line
+ TOOLBAR_BUTTONS: ['profile', 'authentication', 'microphone', 'camera', 'desktop', 'recording', 'security', 'raisehand', 'chat', 'etherpad', 'sharedvideo', 'fullscreen', 'sip', 'dialpad', 'settings', 'hangup', 'filmstrip', 'contacts'], // jshint ignore:line
SETTINGS_SECTIONS: ['language', 'devices', 'moderator'],
// Determines how the video would fit the screen. 'both' would fit the whole
// screen, 'height' would fit the original video height to the height of the
diff --git a/lang/main.json b/lang/main.json
index 443639820..d98229c7d 100644
--- a/lang/main.json
+++ b/lang/main.json
@@ -94,7 +94,8 @@
"unableToUnmutePopup": "You cannot un-mute while the shared video is on.",
"cameraDisabled": "Camera is not available",
"micDisabled": "Microphone is not available",
- "filmstrip": "Show / hide videos"
+ "filmstrip": "Show / hide videos",
+ "raiseHand": "Raise hand to speak"
},
"bottomtoolbar": {
"chat": "Open / close chat",
diff --git a/modules/UI/toolbars/Toolbar.js b/modules/UI/toolbars/Toolbar.js
index d055f70aa..876b6f108 100644
--- a/modules/UI/toolbars/Toolbar.js
+++ b/modules/UI/toolbars/Toolbar.js
@@ -168,8 +168,13 @@ const buttonHandlers = {
},
"toolbar_film_strip": function () {
JitsiMeetJS.analytics.sendEvent(
- 'bottomtoolbar.filmstrip.toggled');
+ 'toolbar.filmstrip.toggled');
emitter.emit(UIEvents.TOGGLE_FILM_STRIP);
+ },
+ "toolbar_button_raisehand": function () {
+ JitsiMeetJS.analytics.sendEvent(
+ 'toolbar.raiseHand.clicked');
+ APP.conference.maybeToggleRaisedHand();
}
};
@@ -288,6 +293,19 @@ const defaultToolbarButtons = {
APP.UI.toggleFilmStrip();
},
shortcutDescription: "keyboardShortcuts.toggleFilmstrip"
+ },
+ 'raisehand': {
+ id: "toolbar_button_raisehand",
+ className: "button icon-raised-hand",
+ shortcut: "R",
+ shortcutAttr: "raiseHandPopover",
+ shortcutFunc: function() {
+ JitsiMeetJS.analytics.sendEvent("shortcut.raisehand.clicked");
+ APP.conference.maybeToggleRaisedHand();
+ },
+ shortcutDescription: "keyboardShortcuts.raiseHand",
+ content: "Raise Hand",
+ i18n: "[content]toolbar.raiseHand"
}
};
@@ -323,10 +341,14 @@ const Toolbar = {
this.toolbarSelector = $("#mainToolbarContainer");
this.extendedToolbarSelector = $("#extendedToolbar");
- this._initMainToolbarButtons();
-
+ // First hide all disabled buttons in the extended toolbar.
+ // TODO: Make the extended toolbar dynamically created.
UIUtil.hideDisabledButtons(defaultToolbarButtons);
+ // Initialise the main toolbar. The main toolbar will only take into
+ // account it's own configuration from interface_config.
+ this._initMainToolbarButtons();
+
Object.keys(defaultToolbarButtons).forEach(
id => {
if (UIUtil.isButtonEnabled(id)) {
@@ -679,16 +701,9 @@ const Toolbar = {
}
);
},
+
/**
- * TODO: Fix mic popups
- *
- *
- *
- *
+ * Initialise main toolbar buttons.
*/
_initMainToolbarButtons() {
interfaceConfig.MAIN_TOOLBAR_BUTTONS.forEach((value, index) => {
diff --git a/modules/UI/util/UIUtil.js b/modules/UI/util/UIUtil.js
index 321de2be9..b55191189 100644
--- a/modules/UI/util/UIUtil.js
+++ b/modules/UI/util/UIUtil.js
@@ -112,7 +112,8 @@
* is enabled, {false} - otherwise
*/
isButtonEnabled: function (name) {
- return interfaceConfig.TOOLBAR_BUTTONS.indexOf(name) !== -1;
+ return interfaceConfig.TOOLBAR_BUTTONS.indexOf(name) !== -1
+ || interfaceConfig.MAIN_TOOLBAR_BUTTONS.indexOf(name) !== -1;
},
/**
* Indicates if the setting section is enabled.
diff --git a/modules/keyboardshortcut/keyboardshortcut.js b/modules/keyboardshortcut/keyboardshortcut.js
index 7a54b7321..4bb98fb2c 100644
--- a/modules/keyboardshortcut/keyboardshortcut.js
+++ b/modules/keyboardshortcut/keyboardshortcut.js
@@ -17,11 +17,6 @@ function initGlobalShortcuts() {
APP.UI.toggleKeyboardShortcutsPanel();
}, "keyboardShortcuts.toggleShortcuts");
- KeyboardShortcut.registerShortcut("R", null, function() {
- JitsiMeetJS.analytics.sendEvent("shortcut.raisedhand.toggled");
- APP.conference.maybeToggleRaisedHand();
- }, "keyboardShortcuts.raiseHand");
-
KeyboardShortcut.registerShortcut("T", null, function() {
JitsiMeetJS.analytics.sendEvent("shortcut.talk.clicked");
APP.conference.muteAudio(true);