Bladeren bron

fix(visitors): gum pending on promotion.

factor2
Hristo Terezov 1 jaar geleden
bovenliggende
commit
2f6b11a6ac
2 gewijzigde bestanden met toevoegingen van 13 en 6 verwijderingen
  1. 0
    5
      conference.js
  2. 13
    1
      react/features/base/conference/actions.ts

+ 0
- 5
conference.js Bestand weergeven

@@ -165,7 +165,6 @@ import { AudioMixerEffect } from './react/features/stream-effects/audio-mixer/Au
165 165
 import { createRnnoiseProcessor } from './react/features/stream-effects/rnnoise';
166 166
 import { handleToggleVideoMuted } from './react/features/toolbox/actions.any';
167 167
 import { muteLocal } from './react/features/video-menu/actions.any';
168
-import { iAmVisitor } from './react/features/visitors/functions';
169 168
 import UIEvents from './service/UI/UIEvents';
170 169
 
171 170
 const logger = Logger.getLogger(__filename);
@@ -705,10 +704,6 @@ export default {
705 704
         const handleInitialTracks = (options, tracks) => {
706 705
             let localTracks = tracks;
707 706
 
708
-            // No local tracks are added when user joins as a visitor.
709
-            if (iAmVisitor(state)) {
710
-                return [];
711
-            }
712 707
             if (options.startWithAudioMuted || room?.isStartAudioMuted()) {
713 708
                 // Always add the track on Safari because of a known issue where audio playout doesn't happen
714 709
                 // if the user joins audio and video muted, i.e., if there is no local media capture.

+ 13
- 1
react/features/base/conference/actions.ts Bestand weergeven

@@ -8,8 +8,15 @@ import { getReplaceParticipant } from '../config/functions';
8 8
 import { connect, disconnect, hangup } from '../connection/actions';
9 9
 import { JITSI_CONNECTION_CONFERENCE_KEY } from '../connection/constants';
10 10
 import { JitsiConferenceEvents, JitsiE2ePingEvents } from '../lib-jitsi-meet';
11
-import { setAudioMuted, setAudioUnmutePermissions, setVideoMuted, setVideoUnmutePermissions } from '../media/actions';
11
+import {
12
+    gumPending,
13
+    setAudioMuted,
14
+    setAudioUnmutePermissions,
15
+    setVideoMuted,
16
+    setVideoUnmutePermissions
17
+} from '../media/actions';
12 18
 import { MEDIA_TYPE } from '../media/constants';
19
+import { IGUMPendingState } from '../media/types';
13 20
 import {
14 21
     dominantSpeakerChanged,
15 22
     participantKicked,
@@ -1052,6 +1059,11 @@ export function redirect(vnode: string, focusJid: string, username: string) {
1052 1059
             .then(() => dispatch(conferenceWillInit()))
1053 1060
             .then(() => dispatch(connect()))
1054 1061
             .then(() => {
1062
+
1063
+                // Clear the gum pending state in case we have set it to pending since we are starting the
1064
+                // conference without tracks.
1065
+                dispatch(gumPending([ MEDIA_TYPE.AUDIO, MEDIA_TYPE.VIDEO ], IGUMPendingState.NONE));
1066
+
1055 1067
                 // FIXME: Workaround for the web version. To be removed once we get rid of conference.js
1056 1068
                 if (typeof APP !== 'undefined') {
1057 1069
                     APP.conference.startConference([]);

Laden…
Annuleren
Opslaan