| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 /** @suppress {duplicate} */ | 5 /** @suppress {duplicate} */ |
| 6 var remoting = remoting || {}; | 6 var remoting = remoting || {}; |
| 7 | 7 |
| 8 (function() { | 8 (function() { |
| 9 | 9 |
| 10 'use strict'; | 10 'use strict'; |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 71 | 71 |
| 72 remoting.DesktopRemotingActivity.prototype.stop = function() { | 72 remoting.DesktopRemotingActivity.prototype.stop = function() { |
| 73 this.isStopped_ = true; | 73 this.isStopped_ = true; |
| 74 if (this.session_) { | 74 if (this.session_) { |
| 75 this.session_.disconnect(remoting.Error.none()); | 75 this.session_.disconnect(remoting.Error.none()); |
| 76 console.log('Disconnected.'); | 76 console.log('Disconnected.'); |
| 77 } else { | 77 } else { |
| 78 console.log('Canceled.'); | 78 console.log('Canceled.'); |
| 79 // Session creation in process, just report it as canceled. | 79 // Session creation in process, just report it as canceled. |
| 80 this.logger_.logSessionStateChange( | 80 this.logger_.logSessionStateChange( |
| 81 remoting.ChromotingEvent.SessionState.CONNECTION_CANCELED, | 81 remoting.ChromotingEvent.SessionState.CONNECTION_CANCELED); |
| 82 remoting.ChromotingEvent.ConnectionError.NONE); | |
| 83 } | 82 } |
| 84 }; | 83 }; |
| 85 | 84 |
| 86 /** | 85 /** |
| 87 * @param {remoting.ConnectionInfo} connectionInfo | 86 * @param {remoting.ConnectionInfo} connectionInfo |
| 88 */ | 87 */ |
| 89 remoting.DesktopRemotingActivity.prototype.onConnected = | 88 remoting.DesktopRemotingActivity.prototype.onConnected = |
| 90 function(connectionInfo) { | 89 function(connectionInfo) { |
| 91 this.connectingDialog_.hide(); | 90 this.connectingDialog_.hide(); |
| 92 remoting.setMode(remoting.AppMode.IN_SESSION); | 91 remoting.setMode(remoting.AppMode.IN_SESSION); |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 163 remoting.DesktopRemotingActivity.prototype.getSession = function() { | 162 remoting.DesktopRemotingActivity.prototype.getSession = function() { |
| 164 return this.session_; | 163 return this.session_; |
| 165 }; | 164 }; |
| 166 | 165 |
| 167 /** @return {remoting.ConnectingDialog} */ | 166 /** @return {remoting.ConnectingDialog} */ |
| 168 remoting.DesktopRemotingActivity.prototype.getConnectingDialog = function() { | 167 remoting.DesktopRemotingActivity.prototype.getConnectingDialog = function() { |
| 169 return this.connectingDialog_; | 168 return this.connectingDialog_; |
| 170 }; | 169 }; |
| 171 | 170 |
| 172 })(); | 171 })(); |
| OLD | NEW |