|
|
@ -1328,7 +1328,7 @@ export default { |
|
|
|
/** |
|
|
|
/** |
|
|
|
* Used by the Breakout Rooms feature to join a breakout room or go back to the main room. |
|
|
|
* Used by the Breakout Rooms feature to join a breakout room or go back to the main room. |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
async joinRoom(roomName, isBreakoutRoom = false) { |
|
|
|
async joinRoom(roomName) { |
|
|
|
this.roomName = roomName; |
|
|
|
this.roomName = roomName; |
|
|
|
|
|
|
|
|
|
|
|
const { tryCreateLocalTracks, errors } = this.createInitialLocalTracks(); |
|
|
|
const { tryCreateLocalTracks, errors } = this.createInitialLocalTracks(); |
|
|
@ -1341,33 +1341,15 @@ export default { |
|
|
|
track.mute(); |
|
|
|
track.mute(); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
this._createRoom(localTracks, isBreakoutRoom); |
|
|
|
this._createRoom(localTracks); |
|
|
|
|
|
|
|
|
|
|
|
return new Promise((resolve, reject) => { |
|
|
|
return new Promise((resolve, reject) => { |
|
|
|
new ConferenceConnector(resolve, reject).connect(); |
|
|
|
new ConferenceConnector(resolve, reject).connect(); |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
_createRoom(localTracks, isBreakoutRoom = false) { |
|
|
|
_createRoom(localTracks) { |
|
|
|
const extraOptions = {}; |
|
|
|
room = connection.initJitsiConference(APP.conference.roomName, this._getConferenceOptions()); |
|
|
|
|
|
|
|
|
|
|
|
if (isBreakoutRoom) { |
|
|
|
|
|
|
|
// We must be in a room already.
|
|
|
|
|
|
|
|
if (!room?.xmpp?.breakoutRoomsComponentAddress) { |
|
|
|
|
|
|
|
throw new Error('Breakout Rooms not enabled'); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// TODO: re-evaluate this. -saghul
|
|
|
|
|
|
|
|
extraOptions.customDomain = room.xmpp.breakoutRoomsComponentAddress; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
room |
|
|
|
|
|
|
|
= connection.initJitsiConference( |
|
|
|
|
|
|
|
APP.conference.roomName, |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
...this._getConferenceOptions(), |
|
|
|
|
|
|
|
...extraOptions |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Filter out the tracks that are muted (except on Safari).
|
|
|
|
// Filter out the tracks that are muted (except on Safari).
|
|
|
|
const tracks = browser.isWebKitBased() ? localTracks : localTracks.filter(track => !track.isMuted()); |
|
|
|
const tracks = browser.isWebKitBased() ? localTracks : localTracks.filter(track => !track.isMuted()); |
|
|
|