Browse Source

Fixed data channel not ready error by deferring own event triggering.

pull/26/head
Simon Eisenmann 11 years ago
parent
commit
b074e77edd
  1. 3
      static/js/mediastream/webrtc.js

3
static/js/mediastream/webrtc.js

@ -647,7 +647,10 @@ define([ @@ -647,7 +647,10 @@ define([
};
WebRTC.prototype.onConnectionStateChange = function(iceConnectionState, currentcall) {
// Defer this to allow native event handlers to complete before running more stuff.
_.defer(_.bind(function() {
this.e.triggerHandler('statechange', [iceConnectionState, currentcall]);
}, this));
};
WebRTC.prototype.onRemoteStreamAdded = function(stream, currentcall) {

Loading…
Cancel
Save