aboutsummaryrefslogtreecommitdiff
path: root/sway
diff options
context:
space:
mode:
authoremersion <contact@emersion.fr>2018-04-24 18:19:26 +0100
committeremersion <contact@emersion.fr>2018-04-24 18:19:26 +0100
commitdf245780d28c89ba50cebe485f622d1b2db8c1fc (patch)
treea39e8c67eae3b8f68bf88ec5e258d538cfd33441 /sway
parent3ed3bdf03f6f4dfde5e71195739239fa962de8bf (diff)
Do not let tiled xwayland views do what they want
Diffstat (limited to 'sway')
-rw-r--r--sway/desktop/xwayland.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/sway/desktop/xwayland.c b/sway/desktop/xwayland.c
index cad9156d..63d9c66e 100644
--- a/sway/desktop/xwayland.c
+++ b/sway/desktop/xwayland.c
@@ -266,10 +266,13 @@ static void handle_request_configure(struct wl_listener *listener, void *data) {
struct wlr_xwayland_surface_configure_event *ev = data;
struct sway_view *view = &xwayland_view->view;
struct wlr_xwayland_surface *xsurface = view->wlr_xwayland_surface;
- // TODO: floating windows are allowed to move around like this, but make
- // sure tiling windows always stay in place.
- wlr_xwayland_surface_configure(xsurface, ev->x, ev->y,
- ev->width, ev->height);
+ if (!xsurface->mapped) {
+ wlr_xwayland_surface_configure(xsurface, ev->x, ev->y,
+ ev->width, ev->height);
+ return;
+ }
+ // TODO: Let floating views do whatever
+ configure(view, view->swayc->x, view->swayc->y, view->width, view->height);
}
static void handle_request_fullscreen(struct wl_listener *listener, void *data) {