[gtk/resizing-fixes] macos: Use shadow size from GdkToplevelSize



commit 0935a50bf5158a35bf242fd8c8abfe4df2850b14
Author: Matthias Clasen <mclasen redhat com>
Date:   Wed Aug 12 08:19:14 2020 -0400

    macos: Use shadow size from GdkToplevelSize

 gdk/macos/gdkmacostoplevelsurface.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/gdk/macos/gdkmacostoplevelsurface.c b/gdk/macos/gdkmacostoplevelsurface.c
index 0e5a2a0ae7..dbfc0f4bcf 100644
--- a/gdk/macos/gdkmacostoplevelsurface.c
+++ b/gdk/macos/gdkmacostoplevelsurface.c
@@ -128,10 +128,12 @@ _gdk_macos_toplevel_surface_present (GdkToplevel       *toplevel,
 
   gdk_toplevel_size_init (&size, bounds_width, bounds_height);
   gdk_toplevel_notify_compute_size (toplevel, &size);
-  g_warn_if_fail (size.width > 0);
-  g_warn_if_fail (size.height > 0);
   width = size.width;
   height = size.height;
+  surface->shadow_left = size.shadow_left;
+  surface->shadow_right = size.shadow_right;
+  surface->shadow_top = size.shadow_top;
+  surface->shadow_bottom = size.shadow_bottom;
 
   if (gdk_toplevel_layout_get_resizable (layout))
     {


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