diff options
author | Deni42 <felsodaniel@gmail.com> | 2018-01-05 12:05:17 +0100 |
---|---|---|
committer | Samuel Mannehed <samuel@cendio.se> | 2018-01-05 12:05:17 +0100 |
commit | 37c609359ab3606cba2b233611adce029a84ac01 (patch) | |
tree | 6fd8486622bb4e06480dea8627b5807af7d8e692 | |
parent | 1f9d0cb12f01524bf2fd17c0ae1c6933fdbcf728 (diff) | |
download | novnc-37c609359ab3606cba2b233611adce029a84ac01.tar.gz |
Fix view_only setting with autoconnect (#985)
updateVisualState() and updateViewOnly() requires an initiated UI.rfb reference, the calls in connect() was made too early.
-rw-r--r-- | app/ui.js | 7 |
1 files changed, 3 insertions, 4 deletions
@@ -1019,10 +1019,6 @@ var UI = { UI.closeAllPanels(); UI.closeConnectPanel(); - UI.updateVisualState('connecting'); - - UI.updateViewOnly(); - var url; url = UI.getSetting('encrypt') ? 'wss' : 'ws'; @@ -1048,6 +1044,9 @@ var UI = { UI.rfb.clipViewport = UI.getSetting('view_clip'); UI.rfb.scaleViewport = UI.getSetting('resize') === 'scale'; UI.rfb.resizeSession = UI.getSetting('resize') === 'remote'; + + UI.updateVisualState('connecting'); + UI.updateViewOnly(); }, disconnect: function() { |