[gtk/wip/chergert/fix-macos-compute-size: 2/3] macos: avoid setHasShadow unless shadow changes
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/chergert/fix-macos-compute-size: 2/3] macos: avoid setHasShadow unless shadow changes
- Date: Fri, 1 Jan 2021 21:09:58 +0000 (UTC)
commit ad617a0e06d40f5295f57e9f5154de7a55924a8e
Author: Christian Hergert <chergert redhat com>
Date: Fri Jan 1 13:09:57 2021 -0800
macos: avoid setHasShadow unless shadow changes
gdk/macos/gdkmacossurface.c | 6 ++++++
1 file changed, 6 insertions(+)
---
diff --git a/gdk/macos/gdkmacossurface.c b/gdk/macos/gdkmacossurface.c
index 7e0c15dfe2..61e249497e 100644
--- a/gdk/macos/gdkmacossurface.c
+++ b/gdk/macos/gdkmacossurface.c
@@ -150,6 +150,12 @@ _gdk_macos_surface_set_shadow (GdkMacosSurface *surface,
g_assert (GDK_IS_MACOS_SURFACE (self));
+ if (self->shadow_top == top &&
+ self->shadow_right == right &&
+ self->shadow_bottom == bottom &&
+ self->shadow_left == left)
+ return;
+
self->shadow_top = top;
self->shadow_right = right;
self->shadow_bottom = bottom;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]