Browse Source

Adds a possibility to add raise hand as a button

master
yanas 8 years ago
parent
commit
99bf4bc44d
3 changed files with 23 additions and 16 deletions
  1. 2
    1
      lang/main.json
  2. 21
    10
      modules/UI/toolbars/Toolbar.js
  3. 0
    5
      modules/keyboardshortcut/keyboardshortcut.js

+ 2
- 1
lang/main.json View File

94
         "unableToUnmutePopup": "You cannot un-mute while the shared video is on.",
94
         "unableToUnmutePopup": "You cannot un-mute while the shared video is on.",
95
         "cameraDisabled": "Camera is not available",
95
         "cameraDisabled": "Camera is not available",
96
         "micDisabled": "Microphone is not available",
96
         "micDisabled": "Microphone is not available",
97
-        "filmstrip": "Show / hide videos"
97
+        "filmstrip": "Show / hide videos",
98
+        "raiseHand": "Raise hand to speak"
98
     },
99
     },
99
     "bottomtoolbar": {
100
     "bottomtoolbar": {
100
         "chat": "Open / close chat",
101
         "chat": "Open / close chat",

+ 21
- 10
modules/UI/toolbars/Toolbar.js View File

168
     },
168
     },
169
     "toolbar_film_strip": function () {
169
     "toolbar_film_strip": function () {
170
         JitsiMeetJS.analytics.sendEvent(
170
         JitsiMeetJS.analytics.sendEvent(
171
-            'bottomtoolbar.filmstrip.toggled');
171
+            'toolbar.filmstrip.toggled');
172
         emitter.emit(UIEvents.TOGGLE_FILM_STRIP);
172
         emitter.emit(UIEvents.TOGGLE_FILM_STRIP);
173
+    },
174
+    "toolbar_button_raisehand": function () {
175
+        JitsiMeetJS.analytics.sendEvent(
176
+            'toolbar.raiseHand.clicked');
177
+        APP.conference.maybeToggleRaisedHand();
173
     }
178
     }
174
 };
179
 };
175
 
180
 
288
             APP.UI.toggleFilmStrip();
293
             APP.UI.toggleFilmStrip();
289
         },
294
         },
290
         shortcutDescription: "keyboardShortcuts.toggleFilmstrip"
295
         shortcutDescription: "keyboardShortcuts.toggleFilmstrip"
296
+    },
297
+    'raisehand': {
298
+        id: "toolbar_button_raisehand",
299
+        className: "button icon-raised-hand",
300
+        shortcut: "R",
301
+        shortcutAttr: "raiseHandPopover",
302
+        shortcutFunc: function() {
303
+            JitsiMeetJS.analytics.sendEvent("shortcut.raisehand.clicked");
304
+            APP.conference.maybeToggleRaisedHand();
305
+        },
306
+        shortcutDescription: "keyboardShortcuts.raiseHand",
307
+        content: "Raise Hand",
308
+        i18n: "[content]toolbar.raiseHand"
291
     }
309
     }
292
 };
310
 };
293
 
311
 
679
             }
697
             }
680
         );
698
         );
681
     },
699
     },
700
+
682
     /**
701
     /**
683
-     * TODO: Fix mic popups
684
-     * <a class="button icon-microphone" id="toolbar_button_mute" data-container="body" data-toggle="popover" data-placement="bottom" shortcut="mutePopover" data-i18n="[content]toolbar.mute" content="Mute / Unmute">
685
-     *   <ul id="micMutedPopup" class="loginmenu">
686
-     *       <li data-i18n="[html]toolbar.micMutedPopup"></li>
687
-     *   </ul>
688
-     *   <ul id="unableToUnmutePopup" class="loginmenu">
689
-     *       <li data-i18n="[html]toolbar.unableToUnmutePopup"></li>
690
-     *   </ul>
691
-     * </a>
702
+     * Initialise main toolbar buttons.
692
      */
703
      */
693
     _initMainToolbarButtons() {
704
     _initMainToolbarButtons() {
694
         interfaceConfig.MAIN_TOOLBAR_BUTTONS.forEach((value, index) => {
705
         interfaceConfig.MAIN_TOOLBAR_BUTTONS.forEach((value, index) => {

+ 0
- 5
modules/keyboardshortcut/keyboardshortcut.js View File

17
         APP.UI.toggleKeyboardShortcutsPanel();
17
         APP.UI.toggleKeyboardShortcutsPanel();
18
     }, "keyboardShortcuts.toggleShortcuts");
18
     }, "keyboardShortcuts.toggleShortcuts");
19
 
19
 
20
-    KeyboardShortcut.registerShortcut("R", null, function() {
21
-        JitsiMeetJS.analytics.sendEvent("shortcut.raisedhand.toggled");
22
-        APP.conference.maybeToggleRaisedHand();
23
-    }, "keyboardShortcuts.raiseHand");
24
-
25
     KeyboardShortcut.registerShortcut("T", null, function() {
20
     KeyboardShortcut.registerShortcut("T", null, function() {
26
         JitsiMeetJS.analytics.sendEvent("shortcut.talk.clicked");
21
         JitsiMeetJS.analytics.sendEvent("shortcut.talk.clicked");
27
         APP.conference.muteAudio(true);
22
         APP.conference.muteAudio(true);

Loading…
Cancel
Save