]> git.proxmox.com Git - novnc-pve.git/commitdiff
request size with vncshell and container console
authorDominik Csapak <d.csapak@proxmox.com>
Wed, 24 May 2017 10:30:49 +0000 (12:30 +0200)
committerWolfgang Bumiller <w.bumiller@proxmox.com>
Wed, 24 May 2017 11:00:43 +0000 (13:00 +0200)
when opening the console*tab* on a host or a container,
give the current size to the vncproxy api call, so that the console
fills the entire tab

resizing the window/iframe does not resize the vnc console
(because libvncserver has no setDesktopSize support)

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
debian/patches/0011-add-width-and-height-to-vncproxy-call-in-console-tab.patch [new file with mode: 0644]
debian/patches/series

diff --git a/debian/patches/0011-add-width-and-height-to-vncproxy-call-in-console-tab.patch b/debian/patches/0011-add-width-and-height-to-vncproxy-call-in-console-tab.patch
new file mode 100644 (file)
index 0000000..ed1f4c3
--- /dev/null
@@ -0,0 +1,33 @@
+From d3da00817202a762de5bcd7cf14c38dceb30a301 Mon Sep 17 00:00:00 2001
+From: Dominik Csapak <d.csapak@proxmox.com>
+Date: Fri, 19 May 2017 08:53:56 +0200
+Subject: [PATCH 11/11] add width and height to vncproxy call in console tab
+
+to set the resolution we want
+
+Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
+---
+ app/pve.js | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/app/pve.js b/app/pve.js
+index 668835a..c10df4e 100644
+--- a/app/pve.js
++++ b/app/pve.js
+@@ -52,6 +52,13 @@ export default function PVEUI(UI){
+           break;
+     }
++    if (this.resize == 'scale' &&
++      (this.consoletype === 'lxc' || this.consoletype === 'shell')) {
++      var size = this.getFBSize();
++      params.width = size.width;
++      params.height = size.height;
++    }
++
+     this.baseUrl = baseUrl;
+     this.url = url;
+     this.params = params;
+-- 
+2.11.0
+
index 086ff4376324e02b1f0d248c10071a379b49edf6..e1b6664308a87996f83e4c4bb0939a4a7f00ad70 100644 (file)
@@ -8,3 +8,4 @@
 0008-focus-canvas-after-load.patch
 0009-decrease-animation-time.patch
 0010-use-only-app.js.patch
+0011-add-width-and-height-to-vncproxy-call-in-console-tab.patch