]> git.proxmox.com Git - mirror_novnc.git/commitdiff
Remove unnecessary code
authorSamuel Mannehed <samuel@cendio.se>
Mon, 30 Jul 2018 08:02:44 +0000 (10:02 +0200)
committerSamuel Mannehed <samuel@cendio.se>
Mon, 30 Jul 2018 08:29:35 +0000 (10:29 +0200)
The enableDisableViewClip call in the fullscreen code didn't have any
effect and should have been removed when the special case for clipping
in IE and Safari fullscreen was removed in b18ef81.

The setViewDrag call claimed to disable view drag on UI state change.
The UI states are:

 init, connecting, connected, reconnecting, disconnecting, disconnected

The only state where the called function didn't immediately return was
"connected" and that's the only state where enabling view drag is
possible. Thus it could never have been enabled when changing to the
"connected" state.

app/ui.js

index 4fe2a3fb0639b83787a849bfcd0e92a8e981fc3e..552ac287d07019de24720592bdc2a5caf269fd11 100644 (file)
--- a/app/ui.js
+++ b/app/ui.js
@@ -432,11 +432,7 @@ const UI = {
             UI.keepControlbar();
         }
 
-        // State change disables viewport dragging.
-        // It is enabled (toggled) by direct click on the button
-        UI.setViewDrag(false);
-
-        // State change also closes the password dialog
+        // State change closes the password dialog
         document.getElementById('noVNC_password_dlg')
             .classList.remove('noVNC_open');
     },
@@ -1204,7 +1200,6 @@ const UI = {
                 document.body.msRequestFullscreen();
             }
         }
-        UI.enableDisableViewClip();
         UI.updateFullscreenButton();
     },