feat(external_api): notify when api is disposed

This commit is contained in:
Gabriel-Tiberiu Imre-Lucaci 2019-02-25 17:34:54 +02:00 committed by Hristo Terezov
parent b6e2701991
commit 5739e1deaa
2 changed files with 2 additions and 1 deletions

View File

@ -256,7 +256,7 @@ changes. The listener will receive an object with the following structure:
* **readyToClose** - event notification fired when Jitsi Meet is ready to be closed (hangup operations are completed). * **readyToClose** - event notification fired when Jitsi Meet is ready to be closed (hangup operations are completed).
* **subjectChange** - event notifications about subject of conference changes. * **subjectChange** - event notifications about subject of conference changes.
The listener will receive an object with the following structure: The listener will receive an object with the following structure:
```javascript ```javascript
{ {

View File

@ -534,6 +534,7 @@ export default class JitsiMeetExternalAPI extends EventEmitter {
* @returns {void} * @returns {void}
*/ */
dispose() { dispose() {
this.emit('_willDispose');
this._transport.dispose(); this._transport.dispose();
this.removeAllListeners(); this.removeAllListeners();
if (this._frame) { if (this._frame) {