Index: remoting/webapp/crd/js/desktop_remoting.js |
diff --git a/remoting/webapp/crd/js/desktop_remoting.js b/remoting/webapp/crd/js/desktop_remoting.js |
index a1838d42c8bc4282cd440662a91687c1bd203b27..416596c9cd185acdfeda182685ffaf7c8af607b9 100644 |
--- a/remoting/webapp/crd/js/desktop_remoting.js |
+++ b/remoting/webapp/crd/js/desktop_remoting.js |
@@ -97,17 +97,9 @@ remoting.DesktopRemoting.prototype.init = function() { |
remoting.optionsMenu = remoting.toolbar.createOptionsMenu(); |
window.addEventListener('beforeunload', remoting.promptClose, false); |
- window.addEventListener('unload', remoting.disconnect, false); |
+ window.addEventListener('unload', remoting.app.disconnect, false); |
Jamie
2015/03/04 01:06:54
bind?
kelvinp
2015/03/04 21:02:21
Done.
|
} |
- // When a window goes full-screen, a resize event is triggered, but the |
- // Fullscreen.isActive call is not guaranteed to return true until the |
- // full-screen event is triggered. In apps v2, the size of the window's |
- // client area is calculated differently in full-screen mode, so register |
- // for both events. |
- window.addEventListener('resize', remoting.onResize, false); |
- remoting.fullscreen.addListener(remoting.onResize); |
Jamie
2015/03/04 01:06:54
This was previously specific to CRD. If there are
kelvinp
2015/03/04 21:02:21
This is a good point. Looking glass should be fin
|
- |
remoting.initHostlist_(); |
var homeFeedback = new remoting.MenuButton( |
@@ -233,6 +225,15 @@ remoting.DesktopRemoting.prototype.handleConnected = function(clientSession) { |
* @return {void} Nothing. |
*/ |
remoting.DesktopRemoting.prototype.handleDisconnected = function() { |
+ if (remoting.desktopConnectedView.getMode() == |
+ remoting.DesktopConnectedView.Mode.IT2ME) { |
+ remoting.setMode(remoting.AppMode.CLIENT_SESSION_FINISHED_IT2ME); |
+ remoting.hangoutSessionEvents.raiseEvent( |
Jamie
2015/03/04 01:06:54
Can we get rid of this now?
kelvinp
2015/03/04 21:02:21
This will be gone after a rebase as it is already
|
+ remoting.hangoutSessionEvents.sessionStateChanged, |
+ remoting.ClientSession.State.CLOSED); |
+ } else { |
+ remoting.setMode(remoting.AppMode.CLIENT_SESSION_FINISHED_ME2ME); |
+ } |
}; |
/** |