瀏覽代碼

Merge branch 'talk-muted'

j8
Lyubomir Marinov 8 年之前
父節點
當前提交
b2a70b263a
共有 5 個檔案被更改,包括 18 行新增4 行删除
  1. 6
    0
      conference.js
  2. 1
    0
      lang/main.json
  3. 2
    2
      modules/UI/UI.js
  4. 5
    0
      modules/UI/toolbars/Toolbar.js
  5. 4
    2
      modules/UI/toolbars/ToolbarToggler.js

+ 6
- 0
conference.js 查看文件

17
 import {reportError} from './modules/util/helpers';
17
 import {reportError} from './modules/util/helpers';
18
 
18
 
19
 import UIErrors from './modules/UI/UIErrors';
19
 import UIErrors from './modules/UI/UIErrors';
20
+import UIUtil from './modules/UI/util/UIUtil';
20
 
21
 
21
 const ConnectionEvents = JitsiMeetJS.events.connection;
22
 const ConnectionEvents = JitsiMeetJS.events.connection;
22
 const ConnectionErrors = JitsiMeetJS.errors.connection;
23
 const ConnectionErrors = JitsiMeetJS.errors.connection;
1278
             APP.UI.setAudioLevel(id, lvl);
1279
             APP.UI.setAudioLevel(id, lvl);
1279
         });
1280
         });
1280
 
1281
 
1282
+        room.on(ConferenceEvents.TALK_WHILE_MUTED, () => {
1283
+            APP.UI.showToolbar(6000);
1284
+            UIUtil.animateShowElement($("#talkWhileMutedPopup"), true, 5000);
1285
+        });
1286
+
1281
         room.on(ConferenceEvents.IN_LAST_N_CHANGED, (inLastN) => {
1287
         room.on(ConferenceEvents.IN_LAST_N_CHANGED, (inLastN) => {
1282
             //FIXME
1288
             //FIXME
1283
             if (config.muteLocalVideoIfNotInLastN) {
1289
             if (config.muteLocalVideoIfNotInLastN) {

+ 1
- 0
lang/main.json 查看文件

90
         "dialpad": "Show dialpad",
90
         "dialpad": "Show dialpad",
91
         "sharedVideoMutedPopup": "Your shared video has been muted so<br/>that you can talk to the other participants.",
91
         "sharedVideoMutedPopup": "Your shared video has been muted so<br/>that you can talk to the other participants.",
92
         "micMutedPopup": "Your microphone has been muted so that you<br/>would fully enjoy your shared video.",
92
         "micMutedPopup": "Your microphone has been muted so that you<br/>would fully enjoy your shared video.",
93
+        "talkWhileMutedPopup": "Trying to speak? You are muted.",
93
         "unableToUnmutePopup": "You cannot un-mute while the shared video is on.",
94
         "unableToUnmutePopup": "You cannot un-mute while the shared video is on.",
94
         "cameraDisabled": "Camera is not available",
95
         "cameraDisabled": "Camera is not available",
95
         "micDisabled": "Microphone is not available",
96
         "micDisabled": "Microphone is not available",

+ 2
- 2
modules/UI/UI.js 查看文件

884
 };
884
 };
885
 
885
 
886
 //Used by torture
886
 //Used by torture
887
-UI.showToolbar = function () {
888
-    return ToolbarToggler.showToolbar();
887
+UI.showToolbar = function (timeout) {
888
+    return ToolbarToggler.showToolbar(timeout);
889
 };
889
 };
890
 
890
 
891
 //Used by torture
891
 //Used by torture

+ 5
- 0
modules/UI/toolbars/Toolbar.js 查看文件

209
                 id: "unableToUnmutePopup",
209
                 id: "unableToUnmutePopup",
210
                 className: "loginmenu",
210
                 className: "loginmenu",
211
                 dataAttr: "[html]toolbar.unableToUnmutePopup"
211
                 dataAttr: "[html]toolbar.unableToUnmutePopup"
212
+            },
213
+            {
214
+                id: "talkWhileMutedPopup",
215
+                className: "loginmenu",
216
+                dataAttr: "[html]toolbar.talkWhileMutedPopup"
212
             }
217
             }
213
         ],
218
         ],
214
         content: "Mute / Unmute",
219
         content: "Mute / Unmute",

+ 4
- 2
modules/UI/toolbars/ToolbarToggler.js 查看文件

89
 
89
 
90
     /**
90
     /**
91
      * Shows the main toolbar.
91
      * Shows the main toolbar.
92
+     * @param timeout (optional) to specify custom timeout value
92
      */
93
      */
93
-    showToolbar () {
94
+    showToolbar (timeout) {
94
         if (interfaceConfig.filmStripOnly) {
95
         if (interfaceConfig.filmStripOnly) {
95
             return;
96
             return;
96
         }
97
         }
107
                 clearTimeout(toolbarTimeoutObject);
108
                 clearTimeout(toolbarTimeoutObject);
108
                 toolbarTimeoutObject = null;
109
                 toolbarTimeoutObject = null;
109
             }
110
             }
110
-            toolbarTimeoutObject = setTimeout(hideToolbar, toolbarTimeout);
111
+            toolbarTimeoutObject
112
+                = setTimeout(hideToolbar, timeout || toolbarTimeout);
111
             toolbarTimeout = interfaceConfig.TOOLBAR_TIMEOUT;
113
             toolbarTimeout = interfaceConfig.TOOLBAR_TIMEOUT;
112
         }
114
         }
113
 
115
 

Loading…
取消
儲存