OLD | NEW |
---|---|
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 /** | 5 /** |
6 * @fileoverview | 6 * @fileoverview |
7 * Class handling creation and teardown of a remoting client session. | 7 * Class handling creation and teardown of a remoting client session. |
8 * | 8 * |
9 * This abstracts a <embed> element and controls the plugin which does the | 9 * This abstracts a <embed> element and controls the plugin which does the |
10 * actual remoting work. There should be no UI code inside this class. It | 10 * actual remoting work. There should be no UI code inside this class. It |
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
195 this.plugin = null; | 195 this.plugin = null; |
196 } | 196 } |
197 }; | 197 }; |
198 | 198 |
199 /** | 199 /** |
200 * Deletes the <embed> element from the container and disconnects. | 200 * Deletes the <embed> element from the container and disconnects. |
201 * | 201 * |
202 * @return {void} Nothing. | 202 * @return {void} Nothing. |
203 */ | 203 */ |
204 remoting.ClientSession.prototype.disconnect = function() { | 204 remoting.ClientSession.prototype.disconnect = function() { |
205 this.logToServer.logClientSessionStateChange( | |
206 remoting.ClientSession.State.CLOSED, | |
207 remoting.ClientSession.ConnectionError.NONE); | |
Jamie
2011/12/02 23:48:26
Please add a comment explaining that we won't get
simonmorris
2011/12/02 23:54:51
Done.
| |
205 if (remoting.wcs) { | 208 if (remoting.wcs) { |
206 remoting.wcs.setOnIq(function(stanza) {}); | 209 remoting.wcs.setOnIq(function(stanza) {}); |
207 this.sendIq_( | 210 this.sendIq_( |
208 '<cli:iq ' + | 211 '<cli:iq ' + |
209 'to="' + this.hostJid + '" ' + | 212 'to="' + this.hostJid + '" ' + |
210 'type="set" ' + | 213 'type="set" ' + |
211 'id="session-terminate" ' + | 214 'id="session-terminate" ' + |
212 'xmlns:cli="jabber:client">' + | 215 'xmlns:cli="jabber:client">' + |
213 '<jingle ' + | 216 '<jingle ' + |
214 'xmlns="urn:xmpp:jingle:1" ' + | 217 'xmlns="urn:xmpp:jingle:1" ' + |
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
411 return { | 414 return { |
412 'video_bandwidth': this.plugin.videoBandwidth, | 415 'video_bandwidth': this.plugin.videoBandwidth, |
413 'video_frame_rate': this.plugin.videoFrameRate, | 416 'video_frame_rate': this.plugin.videoFrameRate, |
414 'capture_latency': this.plugin.videoCaptureLatency, | 417 'capture_latency': this.plugin.videoCaptureLatency, |
415 'encode_latency': this.plugin.videoEncodeLatency, | 418 'encode_latency': this.plugin.videoEncodeLatency, |
416 'decode_latency': this.plugin.videoDecodeLatency, | 419 'decode_latency': this.plugin.videoDecodeLatency, |
417 'render_latency': this.plugin.videoRenderLatency, | 420 'render_latency': this.plugin.videoRenderLatency, |
418 'roundtrip_latency': this.plugin.roundTripLatency | 421 'roundtrip_latency': this.plugin.roundTripLatency |
419 }; | 422 }; |
420 }; | 423 }; |
OLD | NEW |