Notify for detecting suspend.
This commit is contained in:
parent
9e95e7cd97
commit
f77976b742
|
@ -1998,6 +1998,8 @@ export default {
|
||||||
this.localAudio.dispose();
|
this.localAudio.dispose();
|
||||||
this.localAudio = null;
|
this.localAudio = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
APP.API.notifySuspendDetected();
|
||||||
});
|
});
|
||||||
|
|
||||||
APP.UI.addListener(UIEvents.AUDIO_MUTED, muted => {
|
APP.UI.addListener(UIEvents.AUDIO_MUTED, muted => {
|
||||||
|
|
|
@ -437,6 +437,8 @@ The listener will receive an object with the following structure:
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
* **suspendDetected** - event notifications about detecting suspend event in host computer.
|
||||||
|
|
||||||
You can also add multiple event listeners by using `addEventListeners`.
|
You can also add multiple event listeners by using `addEventListeners`.
|
||||||
This method requires one argument of type Object. The object argument must
|
This method requires one argument of type Object. The object argument must
|
||||||
have the names of the events as keys and the listeners of the events as values.
|
have the names of the events as keys and the listeners of the events as values.
|
||||||
|
|
|
@ -509,6 +509,15 @@ class API {
|
||||||
this._sendEvent({ name: 'video-ready-to-close' });
|
this._sendEvent({ name: 'video-ready-to-close' });
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Notify external application (if API is enabled) that a suspend event in host computer.
|
||||||
|
*
|
||||||
|
* @returns {void}
|
||||||
|
*/
|
||||||
|
notifySuspendDetected() {
|
||||||
|
this._sendEvent({ name: 'suspend-detected' });
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Notify external application (if API is enabled) for audio muted status
|
* Notify external application (if API is enabled) for audio muted status
|
||||||
* changed.
|
* changed.
|
||||||
|
|
|
@ -73,6 +73,7 @@ const events = {
|
||||||
'video-mute-status-changed': 'videoMuteStatusChanged',
|
'video-mute-status-changed': 'videoMuteStatusChanged',
|
||||||
'screen-sharing-status-changed': 'screenSharingStatusChanged',
|
'screen-sharing-status-changed': 'screenSharingStatusChanged',
|
||||||
'subject-change': 'subjectChange',
|
'subject-change': 'subjectChange',
|
||||||
|
'suspend-detected': 'suspendDetected',
|
||||||
'tile-view-changed': 'tileViewChanged'
|
'tile-view-changed': 'tileViewChanged'
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -537,6 +538,7 @@ export default class JitsiMeetExternalAPI extends EventEmitter {
|
||||||
* {{
|
* {{
|
||||||
* on: on //whether screen sharing is on
|
* on: on //whether screen sharing is on
|
||||||
* }}
|
* }}
|
||||||
|
* {@code suspendDetected} - receives event notifications about detecting suspend event in host computer.
|
||||||
* {@code readyToClose} - all hangup operations are completed and Jitsi Meet
|
* {@code readyToClose} - all hangup operations are completed and Jitsi Meet
|
||||||
* is ready to be disposed.
|
* is ready to be disposed.
|
||||||
* @returns {void}
|
* @returns {void}
|
||||||
|
|
Loading…
Reference in New Issue