|
@@ -627,7 +627,7 @@ var DataChannels =
|
627
|
627
|
// selections so that it can do adaptive simulcast,
|
628
|
628
|
// we want the notification to trigger even if userJid is undefined,
|
629
|
629
|
// or null.
|
630
|
|
- var userJid = APP.UI.getLargeVideoState().userJid;
|
|
630
|
+ var userJid = APP.UI.getLargeVideoState().userResourceJid;
|
631
|
631
|
// we want the notification to trigger even if userJid is undefined,
|
632
|
632
|
// or null.
|
633
|
633
|
onSelectedEndpointChanged(userJid);
|
|
@@ -785,6 +785,8 @@ function onSelectedEndpointChanged(userResource)
|
785
|
785
|
_dataChannels.some(function (dataChannel) {
|
786
|
786
|
if (dataChannel.readyState == 'open')
|
787
|
787
|
{
|
|
788
|
+ console.log('sending selected endpoint changed '
|
|
789
|
+ + 'notification to the bridge: ', userResource);
|
788
|
790
|
dataChannel.send(JSON.stringify({
|
789
|
791
|
'colibriClass': 'SelectedEndpointChangedEvent',
|
790
|
792
|
'selectedEndpoint':
|
|
@@ -14695,7 +14697,7 @@ module.exports = TraceablePeerConnection;
|
14695
|
14697
|
|
14696
|
14698
|
|
14697
|
14699
|
},{}],53:[function(require,module,exports){
|
14698
|
|
-/* global $, $iq, config, connection, UI, messageHandler,
|
|
14700
|
+/* global $, $iq, APP, config, connection, UI, messageHandler,
|
14699
|
14701
|
roomName, sessionTerminated, Strophe, Util */
|
14700
|
14702
|
var XMPPEvents = require("../../service/xmpp/XMPPEvents");
|
14701
|
14703
|
var Settings = require("../settings/Settings");
|
|
@@ -14964,45 +14966,49 @@ var Moderator = {
|
14964
|
14966
|
}
|
14965
|
14967
|
},
|
14966
|
14968
|
function (error) {
|
|
14969
|
+ // Invalid session ? remove and try again
|
|
14970
|
+ // without session ID to get a new one
|
|
14971
|
+ var invalidSession
|
|
14972
|
+ = $(error).find('>error>session-invalid').length;
|
|
14973
|
+ if (invalidSession) {
|
|
14974
|
+ console.info("Session expired! - removing");
|
|
14975
|
+ localStorage.removeItem("sessionId");
|
|
14976
|
+ }
|
14967
|
14977
|
// Not authorized to create new room
|
14968
|
14978
|
if ($(error).find('>error>not-authorized').length) {
|
14969
|
14979
|
console.warn("Unauthorized to start the conference", error);
|
14970
|
|
-
|
14971
|
|
- if ($(error).find('>error>session-invalid').length) {
|
14972
|
|
- // FIXME: just retry
|
14973
|
|
- console.info("Session expired! - removing");
|
14974
|
|
- localStorage.removeItem("sessionId");
|
14975
|
|
- }
|
14976
|
|
-
|
14977
|
14980
|
var toDomain
|
14978
|
14981
|
= Strophe.getDomainFromJid(error.getAttribute('to'));
|
14979
|
14982
|
if (toDomain === config.hosts.anonymousdomain) {
|
14980
|
14983
|
// we are connected with anonymous domain and
|
14981
|
14984
|
// only non anonymous users can create rooms
|
14982
|
14985
|
// we must authorize the user
|
14983
|
|
-
|
14984
|
14986
|
self.xmppService.promptLogin();
|
14985
|
14987
|
} else {
|
14986
|
|
-
|
14987
|
|
- eventEmitter.emit(XMPPEvents.AUTHENTICATION_REQUIRED, // External authentication mode
|
|
14988
|
+ // External authentication mode
|
|
14989
|
+ eventEmitter.emit(
|
|
14990
|
+ XMPPEvents.AUTHENTICATION_REQUIRED,
|
14988
|
14991
|
function () {
|
14989
|
14992
|
Moderator.allocateConferenceFocus(
|
14990
|
14993
|
roomName, callback);
|
14991
|
14994
|
});
|
14992
|
|
-
|
14993
|
14995
|
}
|
14994
|
14996
|
return;
|
14995
|
14997
|
}
|
14996
|
14998
|
var waitMs = getNextErrorTimeout();
|
14997
|
14999
|
console.error("Focus error, retry after " + waitMs, error);
|
14998
|
15000
|
// Show message
|
14999
|
|
- APP.UI.messageHandler.notify( null, "notify.focus",
|
15000
|
|
- 'Conference focus', 'disconnected',"notify.focusFail",
|
15001
|
|
- Moderator.getFocusComponent() +
|
15002
|
|
- ' not available - retry in ' +
|
15003
|
|
- (waitMs / 1000) + ' sec',
|
15004
|
|
- {component: Moderator.getFocusComponent(),
|
15005
|
|
- ms: (waitMs / 1000)});
|
|
15001
|
+ var focusComponent = Moderator.getFocusComponent();
|
|
15002
|
+ var retrySec = waitMs / 1000;
|
|
15003
|
+ // FIXME: message is duplicated ?
|
|
15004
|
+ // Do not show in case of session invalid
|
|
15005
|
+ // which means just a retry
|
|
15006
|
+ if (!invalidSession) {
|
|
15007
|
+ APP.UI.messageHandler.notify(
|
|
15008
|
+ null, "notify.focus",
|
|
15009
|
+ 'Conference focus', 'disconnected', "notify.focusFail",
|
|
15010
|
+ {component: focusComponent, ms: retrySec});
|
|
15011
|
+ }
|
15006
|
15012
|
// Reset response timeout
|
15007
|
15013
|
getNextTimeout(true);
|
15008
|
15014
|
window.setTimeout(
|