[gtk/wip/chergert/gdk-macos-for-master: 1/3] macos: treat some toplevel NSWindow like document windows




commit a020c901ba2e52e6c8e12551910061037a2c2180
Author: Christian Hergert <chergert redhat com>
Date:   Tue Nov 24 12:39:19 2020 -0800

    macos: treat some toplevel NSWindow like document windows
    
    This makes the window animate in by the window manager like other
    application windows on macOS. Currently ignored for transient windows.

 gdk/macos/gdkmacostoplevelsurface.c | 2 ++
 1 file changed, 2 insertions(+)
---
diff --git a/gdk/macos/gdkmacostoplevelsurface.c b/gdk/macos/gdkmacostoplevelsurface.c
index a9a6488419..05d88ba94f 100644
--- a/gdk/macos/gdkmacostoplevelsurface.c
+++ b/gdk/macos/gdkmacostoplevelsurface.c
@@ -174,6 +174,8 @@ _gdk_macos_toplevel_surface_present (GdkToplevel       *toplevel,
     }
   else
     {
+      [nswindow setAnimationBehavior:NSWindowAnimationBehaviorDocumentWindow];
+
       if (!self->decorated &&
           !GDK_MACOS_SURFACE (self)->did_initial_present &&
           GDK_SURFACE (self)->x == 0 &&


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