|
@@ -449,9 +449,9 @@ JitsiConference.prototype.getRecordingURL = function () {
|
449
|
449
|
* Starts/stops the recording
|
450
|
450
|
* @param token a token for authentication.
|
451
|
451
|
*/
|
452
|
|
-JitsiConference.prototype.toggleRecording = function (token) {
|
|
452
|
+JitsiConference.prototype.toggleRecording = function (token, followEntity) {
|
453
|
453
|
if(this.room)
|
454
|
|
- return this.room.toggleRecording(token);
|
|
454
|
+ return this.room.toggleRecording(token, followEntity);
|
455
|
455
|
return new Promise(function(resolve, reject){
|
456
|
456
|
reject(new Error("The conference is not created yet!"))});
|
457
|
457
|
}
|
|
@@ -6503,9 +6503,9 @@ ChatRoom.prototype.getRecordingURL = function () {
|
6503
|
6503
|
* Starts/stops the recording
|
6504
|
6504
|
* @param token token for authentication
|
6505
|
6505
|
*/
|
6506
|
|
-ChatRoom.prototype.toggleRecording = function (token) {
|
|
6506
|
+ChatRoom.prototype.toggleRecording = function (token, followEntity) {
|
6507
|
6507
|
if(this.recording)
|
6508
|
|
- return this.recording.toggleRecording(token);
|
|
6508
|
+ return this.recording.toggleRecording(token, followEntity);
|
6509
|
6509
|
|
6510
|
6510
|
return new Promise(function(resolve, reject){
|
6511
|
6511
|
reject(new Error("The conference is not created yet!"))});
|
|
@@ -10725,8 +10725,8 @@ Recording.prototype.handleJibriPresence = function (jibri) {
|
10725
|
10725
|
this.eventEmitter.emit(XMPPEvents.RECORDING_STATE_CHANGED);
|
10726
|
10726
|
};
|
10727
|
10727
|
|
10728
|
|
-Recording.prototype.setRecording = function (state, streamId, callback,
|
10729
|
|
- errCallback){
|
|
10728
|
+Recording.prototype.setRecording = function (state, streamId, followEntity,
|
|
10729
|
+ callback, errCallback){
|
10730
|
10730
|
if (state == this.state){
|
10731
|
10731
|
return;
|
10732
|
10732
|
}
|
|
@@ -10735,13 +10735,14 @@ Recording.prototype.setRecording = function (state, streamId, callback,
|
10735
|
10735
|
|
10736
|
10736
|
var iq = $iq({to: this.focusMucJid, type: 'set'})
|
10737
|
10737
|
.c('jibri', {
|
10738
|
|
- xmlns: 'http://jitsi.org/protocol/jibri',
|
10739
|
|
- action: (state === 'on') ? 'start' : 'stop',
|
10740
|
|
- streamid: streamId
|
|
10738
|
+ "xmlns": 'http://jitsi.org/protocol/jibri',
|
|
10739
|
+ "action": (state === 'on') ? 'start' : 'stop',
|
|
10740
|
+ "streamid": streamId,
|
|
10741
|
+ "follow-entity": followEntity
|
10741
|
10742
|
}).up();
|
10742
|
10743
|
|
10743
|
|
- logger.log('Set jibri recording: '+state, iq);
|
10744
|
|
-
|
|
10744
|
+ logger.log('Set jibri recording: '+state, iq.nodeTree);
|
|
10745
|
+ console.log(iq.nodeTree);
|
10745
|
10746
|
this.connection.sendIQ(
|
10746
|
10747
|
iq,
|
10747
|
10748
|
function (result) {
|
|
@@ -10754,7 +10755,7 @@ Recording.prototype.setRecording = function (state, streamId, callback,
|
10754
|
10755
|
});
|
10755
|
10756
|
};
|
10756
|
10757
|
|
10757
|
|
-Recording.prototype.toggleRecording = function (token) {
|
|
10758
|
+Recording.prototype.toggleRecording = function (token, followEntity) {
|
10758
|
10759
|
var self = this;
|
10759
|
10760
|
return new Promise(function(resolve, reject) {
|
10760
|
10761
|
if (!token) {
|
|
@@ -10772,7 +10773,7 @@ Recording.prototype.toggleRecording = function (token) {
|
10772
|
10773
|
var newState = (oldState === 'off' || !oldState) ? 'on' : 'off';
|
10773
|
10774
|
|
10774
|
10775
|
self.setRecording(newState,
|
10775
|
|
- token,
|
|
10776
|
+ token, followEntity,
|
10776
|
10777
|
function (state, url) {
|
10777
|
10778
|
logger.log("New recording state: ", state);
|
10778
|
10779
|
if (state && state !== oldState) {
|
|
@@ -11424,9 +11425,11 @@ module.exports = function() {
|
11424
|
11425
|
logger.info('Dial result ', result);
|
11425
|
11426
|
|
11426
|
11427
|
var resource = $(result).find('ref').attr('uri');
|
11427
|
|
- self.call_resource = resource.substr('xmpp:'.length);
|
|
11428
|
+ self.call_resource =
|
|
11429
|
+ resource.substr('xmpp:'.length);
|
11428
|
11430
|
logger.info(
|
11429
|
|
- "Received call resource: " + self.call_resource);
|
|
11431
|
+ "Received call resource: " +
|
|
11432
|
+ self.call_resource);
|
11430
|
11433
|
resolve();
|
11431
|
11434
|
},
|
11432
|
11435
|
function (error) {
|