mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-10-20 22:27:31 +09:00
Bug 1464079 - Bring ICE connection state change callback up to spec. r=jib, a=RyanVM
This commit is contained in:
parent
e659309611
commit
03766e63da
1 changed files with 12 additions and 0 deletions
|
|
@ -516,6 +516,18 @@ RTCPeerConnection.prototype = {
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
|
||||||
|
// This implements the fairly common "Queue a task" logic
|
||||||
|
async _queueTaskWithClosedCheck(func) {
|
||||||
|
return new Promise(resolve => {
|
||||||
|
Services.tm.mainThread.dispatch({ run() {
|
||||||
|
if (!this._closed) {
|
||||||
|
func();
|
||||||
|
resolve();
|
||||||
|
}
|
||||||
|
}}, Ci.nsIThread.DISPATCH_NORMAL);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* An RTCConfiguration may look like this:
|
* An RTCConfiguration may look like this:
|
||||||
*
|
*
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue