[gtk/gtk-3-24: 1/3] wayland: Update saved size when maximized/fullscreen



commit a393e2ef33b1220fd8365f350202b0e7a12004e2
Author: Olivier Fourdan <ofourdan redhat com>
Date:   Tue Oct 2 17:49:19 2018 +0200

    wayland: Update saved size when maximized/fullscreen
    
    If a client issues a `move_resize()` request while the window is
    maximized or fullscreen, update the saved size for when it will be
    unmaximized/unfullscreened
    
    Related: https://gitlab.gnome.org/GNOME/gtk/issues/1044

 gdk/wayland/gdkwindow-wayland.c | 6 ++++++
 1 file changed, 6 insertions(+)
---
diff --git a/gdk/wayland/gdkwindow-wayland.c b/gdk/wayland/gdkwindow-wayland.c
index 1c62c8f65e..b5d427ce31 100644
--- a/gdk/wayland/gdkwindow-wayland.c
+++ b/gdk/wayland/gdkwindow-wayland.c
@@ -3311,6 +3311,12 @@ gdk_window_wayland_move_resize (GdkWindow *window,
         }
     }
 
+  if (window->state & (GDK_WINDOW_STATE_FULLSCREEN | GDK_WINDOW_STATE_MAXIMIZED))
+    {
+      impl->saved_width = width;
+      impl->saved_height = height;
+    }
+
   /* If this function is called with width and height = -1 then that means
    * just move the window - don't update its size
    */


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