Explorar el Código

Renames performanceTimes to ConnectionTimes

dev1
hristoterezov hace 9 años
padre
commit
3c94755413

+ 4
- 4
JitsiConference.js Ver fichero

826
 };
826
 };
827
 
827
 
828
 /**
828
 /**
829
- * Returns measured performanceTimes.
829
+ * Returns measured connectionTimes.
830
  */
830
  */
831
-JitsiConference.prototype.getPerformanceTimes = function () {
832
-    return this.room.performanceTimes;
831
+JitsiConference.prototype.getConnectionTimes = function () {
832
+    return this.room.connectionTimes;
833
 };
833
 };
834
 
834
 
835
 /**
835
 /**
866
         if (conference.room.isFocus(jingleSession.peerjid)) {
866
         if (conference.room.isFocus(jingleSession.peerjid)) {
867
             // Accept incoming call
867
             // Accept incoming call
868
             conference.room.setJingleSession(jingleSession);
868
             conference.room.setJingleSession(jingleSession);
869
-            conference.room.performanceTimes["session.initiate"] = now;
869
+            conference.room.connectionTimes["session.initiate"] = now;
870
             jingleSession.initialize(false /* initiator */, conference.room);
870
             jingleSession.initialize(false /* initiator */, conference.room);
871
             conference.rtc.onIncommingCall(jingleSession);
871
             conference.rtc.onIncommingCall(jingleSession);
872
             jingleSession.acceptOffer(jingleOffer, null,
872
             jingleSession.acceptOffer(jingleOffer, null,

+ 3
- 3
JitsiConnection.js Ver fichero

94
 }
94
 }
95
 
95
 
96
 /**
96
 /**
97
- * Returns measured performanceTimes.
97
+ * Returns measured connectionTimes.
98
  */
98
  */
99
-JitsiConnection.prototype.getPerformanceTimes = function () {
100
-    return this.xmpp.performanceTimes;
99
+JitsiConnection.prototype.getConnectionTimes = function () {
100
+    return this.xmpp.connectionTimes;
101
 };
101
 };
102
 
102
 
103
 module.exports = JitsiConnection;
103
 module.exports = JitsiConnection;

+ 3
- 3
connection_optimization/external_connect.js Ver fichero

33
 
33
 
34
     xhttp.onreadystatechange = function() {
34
     xhttp.onreadystatechange = function() {
35
         if (xhttp.readyState == xhttp.DONE) {
35
         if (xhttp.readyState == xhttp.DONE) {
36
-            var now = window.performanceTimes["external_connect.done"] =
36
+            var now = window.connectionTimes["external_connect.done"] =
37
                 window.performance.now();
37
                 window.performance.now();
38
             console.log("(TIME) external connect XHR done:\t", now);
38
             console.log("(TIME) external connect XHR done:\t", now);
39
             if (xhttp.status == HTTP_STATUS_OK) {
39
             if (xhttp.status == HTTP_STATUS_OK) {
53
     xhttp.timeout = 3000;
53
     xhttp.timeout = 3000;
54
 
54
 
55
     xhttp.open("GET", webserviceUrl, true);
55
     xhttp.open("GET", webserviceUrl, true);
56
-    window.performanceTimes = {};
57
-    var now = window.performanceTimes["external_connect.sending"] =
56
+    window.connectionTimes = {};
57
+    var now = window.connectionTimes["external_connect.sending"] =
58
         window.performance.now();
58
         window.performance.now();
59
     console.log("(TIME) Sending external connect XHR:\t", now);
59
     console.log("(TIME) Sending external connect XHR:\t", now);
60
     xhttp.send();
60
     xhttp.send();

+ 2
- 2
modules/xmpp/ChatRoom.js Ver fichero

83
     this.lastPresences = {};
83
     this.lastPresences = {};
84
     this.phoneNumber = null;
84
     this.phoneNumber = null;
85
     this.phonePin = null;
85
     this.phonePin = null;
86
-    this.performanceTimes = {};
86
+    this.connectionTimes = {};
87
 }
87
 }
88
 
88
 
89
 ChatRoom.prototype.initPresenceMap = function () {
89
 ChatRoom.prototype.initPresenceMap = function () {
264
         }
264
         }
265
         if (!this.joined) {
265
         if (!this.joined) {
266
             this.joined = true;
266
             this.joined = true;
267
-            var now = this.performanceTimes["muc.joined"] =
267
+            var now = this.connectionTimes["muc.joined"] =
268
                 window.performance.now();
268
                 window.performance.now();
269
             logger.log("(TIME) MUC joined:\t", now);
269
             logger.log("(TIME) MUC joined:\t", now);
270
             this.eventEmitter.emit(XMPPEvents.MUC_JOINED);
270
             this.eventEmitter.emit(XMPPEvents.MUC_JOINED);

+ 1
- 1
modules/xmpp/JingleSessionPC.js Ver fichero

153
     this.peerconnection.oniceconnectionstatechange = function (event) {
153
     this.peerconnection.oniceconnectionstatechange = function (event) {
154
         if (!(self && self.peerconnection)) return;
154
         if (!(self && self.peerconnection)) return;
155
         var now = window.performance.now();
155
         var now = window.performance.now();
156
-        self.room.performanceTimes["ice.state." +
156
+        self.room.connectionTimes["ice.state." +
157
             self.peerconnection.iceConnectionState] = now;
157
             self.peerconnection.iceConnectionState] = now;
158
         logger.log("(TIME) ICE " + self.peerconnection.iceConnectionState +
158
         logger.log("(TIME) ICE " + self.peerconnection.iceConnectionState +
159
                     ":\t", now);
159
                     ":\t", now);

+ 3
- 3
modules/xmpp/xmpp.js Ver fichero

37
     this.eventEmitter = new EventEmitter();
37
     this.eventEmitter = new EventEmitter();
38
     this.connection = null;
38
     this.connection = null;
39
     this.disconnectInProgress = false;
39
     this.disconnectInProgress = false;
40
-    this.performanceTimes = {};
40
+    this.connectionTimes = {};
41
     this.forceMuted = false;
41
     this.forceMuted = false;
42
     this.options = options;
42
     this.options = options;
43
     initStrophePlugins(this);
43
     initStrophePlugins(this);
62
  */
62
  */
63
 XMPP.prototype.connectionHandler = function (password, status, msg) {
63
 XMPP.prototype.connectionHandler = function (password, status, msg) {
64
     var now = window.performance.now();
64
     var now = window.performance.now();
65
-    this.performanceTimes[Strophe.getStatusString(status).toLowerCase()] = now;
65
+    this.connectionTimes[Strophe.getStatusString(status).toLowerCase()] = now;
66
     logger.log("(TIME) Strophe " + Strophe.getStatusString(status) +
66
     logger.log("(TIME) Strophe " + Strophe.getStatusString(status) +
67
         (msg ? "[" + msg + "]" : "") + ":\t", now);
67
         (msg ? "[" + msg + "]" : "") + ":\t", now);
68
     if (status === Strophe.Status.CONNECTED ||
68
     if (status === Strophe.Status.CONNECTED ||
169
  * @param options {object} connecting options - rid, sid, jid and password.
169
  * @param options {object} connecting options - rid, sid, jid and password.
170
  */
170
  */
171
  XMPP.prototype.attach = function (options) {
171
  XMPP.prototype.attach = function (options) {
172
-    var now = this.performanceTimes["attaching"] = window.performance.now();
172
+    var now = this.connectionTimes["attaching"] = window.performance.now();
173
     logger.log("(TIME) Strophe Attaching\t:" + now);
173
     logger.log("(TIME) Strophe Attaching\t:" + now);
174
     this.connection.attach(options.jid, options.sid, parseInt(options.rid,10)+1,
174
     this.connection.attach(options.jid, options.sid, parseInt(options.rid,10)+1,
175
         this.connectionHandler.bind(this, options.password));
175
         this.connectionHandler.bind(this, options.password));

Loading…
Cancelar
Guardar