summaryrefslogtreecommitdiff
path: root/src/ui
diff options
context:
space:
mode:
authorJasper St. Pierre <jstpierre@mecheye.net>2015-06-23 15:23:45 -0700
committerJasper St. Pierre <jstpierre@mecheye.net>2015-06-23 15:27:52 -0700
commit12771a555a9954ba9f002b7e422385cf2e904e86 (patch)
treefeb2ca305cd15c4887f5efb35ca85395078859e7 /src/ui
parent92d6a69153172c41ceb9a78bb817836986b22b24 (diff)
downloadmutter-12771a555a9954ba9f002b7e422385cf2e904e86.tar.gz
theme: Make sure to clear the entirety of buttons properly
In commit cc5def1, buttons were changed from GdkRectangles to MetaButtonSpace units, but the corresponding memset hack was not. This means that the clickable portion of the unshade rectangle was always set to uninitalized memory. The effects of this were random, but in cases where the moon is aligned just right, the rectangle would graze over the borders, and so it would take priority over other borders and show a pointer cursor instead of a resize cursor.
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/theme-private.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ui/theme-private.h b/src/ui/theme-private.h
index cdf23a038..a61457e01 100644
--- a/src/ui/theme-private.h
+++ b/src/ui/theme-private.h
@@ -115,7 +115,7 @@ struct _MetaFrameGeometry
/* used for a memset hack */
#define ADDRESS_OF_BUTTON_RECTS(fgeom) (((char*)(fgeom)) + G_STRUCT_OFFSET (MetaFrameGeometry, close_rect))
-#define LENGTH_OF_BUTTON_RECTS (G_STRUCT_OFFSET (MetaFrameGeometry, unstick_rect) + sizeof (GdkRectangle) - G_STRUCT_OFFSET (MetaFrameGeometry, close_rect))
+#define LENGTH_OF_BUTTON_RECTS (G_STRUCT_OFFSET (MetaFrameGeometry, unstick_rect) + sizeof (MetaButtonSpace) - G_STRUCT_OFFSET (MetaFrameGeometry, close_rect))
/* The button rects (if changed adjust memset hack) */
MetaButtonSpace close_rect;