Преглед изворни кода

ref(conference.js): show screensharing error first

If there will be microphone error it will cover any screensharing
dialog, but it's still better than in the reverse order where
the screensharing dialog will sometime be closing the microphone alert
($.prompt.close(); is called).
j8
paweldomas пре 8 година
родитељ
комит
117d3bb110
1 измењених фајлова са 8 додато и 12 уклоњено
  1. 8
    12
      conference.js

+ 8
- 12
conference.js Прегледај датотеку

558
             .then(([tracks, con]) => {
558
             .then(([tracks, con]) => {
559
                 APP.store.dispatch(
559
                 APP.store.dispatch(
560
                     mediaPermissionPromptVisibilityChanged(false));
560
                     mediaPermissionPromptVisibilityChanged(false));
561
+                // FIXME If there will be microphone error it will cover any
562
+                // screensharing dialog, but it's still better than in
563
+                // the reverse order where the screensharing dialog will
564
+                // sometime be closing the microphone alert ($.prompt.close();
565
+                // is called). Need to figure out dialogs chaining to fix that.
566
+                if (screenSharingError) {
567
+                    this._handleScreenSharingError(screenSharingError);
568
+                }
561
                 if (audioAndVideoError || audioOnlyError) {
569
                 if (audioAndVideoError || audioOnlyError) {
562
                     if (audioOnlyError || videoOnlyError) {
570
                     if (audioOnlyError || videoOnlyError) {
563
                         // If both requests for 'audio' + 'video' and 'audio'
571
                         // If both requests for 'audio' + 'video' and 'audio'
573
                     }
581
                     }
574
                 }
582
                 }
575
 
583
 
576
-                // FIXME If there was a screen sharing error or the extension
577
-                // needs to be installed it will appear on top of eventual
578
-                // "microphone error" dialog. That is not great, but currently
579
-                // it's pretty hard to chain dialogs since they don't return
580
-                // Promises.
581
-                if (screenSharingError) {
582
-                    // FIXME if _handleScreenSharingError will be dealing with
583
-                    // installing external extension it may close previously
584
-                    // opened microphone dialog ($.prompt.close(); is called).
585
-                    this._handleScreenSharingError(screenSharingError);
586
-                }
587
-
588
                 return [tracks, con];
584
                 return [tracks, con];
589
             });
585
             });
590
     },
586
     },

Loading…
Откажи
Сачувај