[gtk/wip/chergert/for-main: 9/10] macos: configure before using position when monitor changes




commit 2ebd641381fb3f153826204460cae088fc59732e
Author: Christian Hergert <christian hergert me>
Date:   Mon Feb 28 22:55:24 2022 -0800

    macos: configure before using position when monitor changes
    
    We need to be sure we have updated values before we use them as the monitor
    changed event might come in before the frame changed configuration. This
    ensures that even if that happens, we get fresh values from the NSWindow
    contentView position.

 gdk/macos/gdkmacossurface.c | 1 +
 1 file changed, 1 insertion(+)
---
diff --git a/gdk/macos/gdkmacossurface.c b/gdk/macos/gdkmacossurface.c
index 28f5601909..1daf571f65 100644
--- a/gdk/macos/gdkmacossurface.c
+++ b/gdk/macos/gdkmacossurface.c
@@ -1082,6 +1082,7 @@ _gdk_macos_surface_monitor_changed (GdkMacosSurface *self)
   self->in_change_monitor = TRUE;
 
   _gdk_macos_surface_cancel_frame (self);
+  _gdk_macos_surface_configure (self);
 
   rect.x = self->root_x;
   rect.y = self->root_y;


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