mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2025-01-14 14:20:21 +00:00
wayland: Don't send invalid anchor rectangles
When we send an anchor rectangle with a width or height of 0, mutter reponds with "Invalid anchor rectangle size". So, don't do that. This was seen as sudden disappearance of gtk4-demo when you click the fishbowl benchmark all the way through to the menubuttons. Fixes: #3027
This commit is contained in:
parent
2bf9ae005f
commit
a85fc0008c
@ -2318,8 +2318,8 @@ create_dynamic_positioner (GdkSurface *surface,
|
||||
real_anchor_rect_x = anchor_rect->x - parent->shadow_left;
|
||||
real_anchor_rect_y = anchor_rect->y - parent->shadow_top;
|
||||
|
||||
anchor_rect_width = anchor_rect->width;
|
||||
anchor_rect_height = anchor_rect->height;
|
||||
anchor_rect_width = MAX (anchor_rect->width, 1);
|
||||
anchor_rect_height = MAX (anchor_rect->height, 1);
|
||||
|
||||
gdk_popup_layout_get_offset (layout, &rect_anchor_dx, &rect_anchor_dy);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user