aboutsummaryrefslogtreecommitdiff
path: root/xwayland
diff options
context:
space:
mode:
authorTony Crisci <tony@dubstepdish.com>2017-10-24 13:57:10 -0400
committerTony Crisci <tony@dubstepdish.com>2017-10-24 13:57:10 -0400
commitfa94a06fd6141a82697a0ae1ba548686f325da45 (patch)
treeb02496a52c21c9f02d91a58e8ad174aad27570e6 /xwayland
parenta9d70a625697dcbe6017aca104a6b649c7ae0ac0 (diff)
xwm: handle configure notify
Diffstat (limited to 'xwayland')
-rw-r--r--xwayland/xwm.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/xwayland/xwm.c b/xwayland/xwm.c
index b8168431..f72f58b2 100644
--- a/xwayland/xwm.c
+++ b/xwayland/xwm.c
@@ -535,6 +535,21 @@ static void handle_configure_request(struct wlr_xwm *xwm,
}
}
+static void handle_configure_notify(struct wlr_xwm *xwm,
+ xcb_configure_notify_event_t *ev) {
+ struct wlr_xwayland_surface *xsurface =
+ lookup_surface_any(xwm, ev->window);
+
+ if (!xsurface) {
+ return;
+ }
+
+ xsurface->x = ev->x;
+ xsurface->y = ev->y;
+ xsurface->width = ev->width;
+ xsurface->height = ev->height;
+}
+
static void handle_map_request(struct wlr_xwm *xwm,
xcb_map_request_event_t *ev) {
wlr_log(L_DEBUG, "XCB_MAP_REQUEST (%u)", ev->window);
@@ -630,6 +645,9 @@ static int x11_event_handler(int fd, uint32_t mask, void *data) {
case XCB_CONFIGURE_REQUEST:
handle_configure_request(xwm, (xcb_configure_request_event_t *)event);
break;
+ case XCB_CONFIGURE_NOTIFY:
+ handle_configure_notify(xwm, (xcb_configure_notify_event_t *)event);
+ break;
case XCB_MAP_REQUEST:
handle_map_request(xwm, (xcb_map_request_event_t *)event);
break;