From a9df4bb81adb0435cd8eeb6a634c963ba33784a7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20=C3=85dahl?= Date: Wed, 16 Sep 2015 14:20:24 +0800 Subject: [PATCH] wayland: Scale saved rect changing monitor scale The saved rect is used to restore a saved window size. We need to update this when the window is moved to a monitor with different scale, so that if we unmaximize a window which was moved to a different monitor while maximized (for example when unplugged) will restore to the correct size. https://bugzilla.gnome.org/show_bug.cgi?id=755097 --- src/wayland/meta-window-wayland.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/wayland/meta-window-wayland.c b/src/wayland/meta-window-wayland.c index 8e1be30aa..8129cb80c 100644 --- a/src/wayland/meta-window-wayland.c +++ b/src/wayland/meta-window-wayland.c @@ -362,6 +362,7 @@ meta_window_wayland_main_monitor_changed (MetaWindow *window, /* Window size. */ scale_rect_size (&window->rect, scale_factor); scale_rect_size (&window->unconstrained_rect, scale_factor); + scale_rect_size (&window->saved_rect, scale_factor); /* Window geometry offset (XXX: Need a better place, see * meta_window_wayland_move_resize). */