[PATCH] window: Do not allow resizing when not in "Normal Size"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Our zoom treatment increases/decreases the window size according to the
action fo zooming in/out. Having it in mind, resizing a window that has
a specified zoom level set may trigger undesired behaviors like:
- too high resolution when zooming in for several times and then
  increasing the window size (black stripes may appear)
- too low resolution when zooming out for several times and then
  decreasing the window size (undesired resizing may happen)
---
 src/virt-viewer-window.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/virt-viewer-window.c b/src/virt-viewer-window.c
index a1b9940..2ab372b 100644
--- a/src/virt-viewer-window.c
+++ b/src/virt-viewer-window.c
@@ -1419,6 +1419,7 @@ virt_viewer_window_set_zoom_level(VirtViewerWindow *self, gint zoom_level)
     virt_viewer_display_set_zoom_level(VIRT_VIEWER_DISPLAY(priv->display), priv->zoomlevel);
 
     virt_viewer_window_queue_resize(self);
+    gtk_window_set_resizable(GTK_WINDOW(self->priv->window), priv->zoomlevel == 100);
 }
 
 gint virt_viewer_window_get_zoom_level(VirtViewerWindow *self)
-- 
2.5.0

_______________________________________________
virt-tools-list mailing list
virt-tools-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/virt-tools-list



[Index of Archives]     [Linux Virtualization]     [KVM Development]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]     [Video 4 Linux]

  Powered by Linux