From d9b021916aa79d4c37ed7622719e97efca830ccb Mon Sep 17 00:00:00 2001 From: Joshua Ashton Date: Sun, 17 Oct 2021 18:34:49 +0000 Subject: [PATCH] xwayland: Handle min width/height in configure Signed-off-by: Joshua Ashton --- src/xwayland.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/xwayland.c b/src/xwayland.c index 9fc60b95..345eb2df 100644 --- a/src/xwayland.c +++ b/src/xwayland.c @@ -97,8 +97,15 @@ handle_request_configure(struct wl_listener *listener, void *data) { struct view *view = wl_container_of(listener, view, request_configure); struct wlr_xwayland_surface_configure_event *event = data; - wlr_xwayland_surface_configure(view->xwayland_surface, event->x, - event->y, event->width, event->height); + + int min_width, min_height; + view_min_size(view, &min_width, &min_height); + + wlr_xwayland_surface_configure(view->xwayland_surface, + event->x, + event->y, + max(event->width, min_width), + max(event->height, min_height)); damage_all_outputs(view->server); }