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

feat(conference): hide user media permission overlay when tracks are created

j8
Lyubo Marinov пре 8 година
родитељ
комит
bf7b723891
1 измењених фајлова са 7 додато и 5 уклоњено
  1. 7
    5
      conference.js

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

632
                 });
632
                 });
633
         }
633
         }
634
 
634
 
635
-        // Hide permissions overlay when tracks are created
636
-        tryCreateLocalTracks.then(() => {
637
-            APP.store.dispatch(
638
-                mediaPermissionPromptVisibilityChanged(false));
639
-        });
635
+        // Hide the permissions prompt/overlay as soon as the tracks are
636
+        // created. Don't wait for the connection to be made, since in some
637
+        // cases, when auth is rquired, for instance, that won't happen until
638
+        // the user inputs their credentials, but the dialog would be
639
+        // overshadowed by the overlay.
640
+        tryCreateLocalTracks.then(() =>
641
+            APP.store.dispatch(mediaPermissionPromptVisibilityChanged(false)));
640
 
642
 
641
         return Promise.all([ tryCreateLocalTracks, connect(roomName) ])
643
         return Promise.all([ tryCreateLocalTracks, connect(roomName) ])
642
             .then(([ tracks, con ]) => {
644
             .then(([ tracks, con ]) => {

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