diff options
| author | DDoSolitary <DDoSolitary@gmail.com> | 2025-01-28 00:45:15 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-01-27 17:45:15 +0100 |
| commit | e7a72de9b5550784ea804c7bb4e84a28a74326a8 (patch) | |
| tree | c6a55bb6ca93ccc06e6b63693717b4d1064365f1 /src | |
| parent | cb7ed4f62b195ab7d5f21fa393218170cfbb95c8 (diff) | |
xwayland: send synthetic configure events (#9193)
Diffstat (limited to 'src')
| -rw-r--r-- | src/xwayland/XSurface.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/xwayland/XSurface.cpp b/src/xwayland/XSurface.cpp index b5ee75f6..91f20be5 100644 --- a/src/xwayland/XSurface.cpp +++ b/src/xwayland/XSurface.cpp @@ -169,6 +169,22 @@ void CXWaylandSurface::configure(const CBox& box) { uint32_t values[] = {box.x, box.y, box.width, box.height, 0}; xcb_configure_window(g_pXWayland->pWM->connection, xID, mask, values); + if (geometry.width == box.width && geometry.height == box.height) { + // ICCCM requires a synthetic event when window size is not changed + xcb_configure_notify_event_t e; + e.response_type = XCB_CONFIGURE_NOTIFY; + e.event = xID; + e.window = xID; + e.x = box.x; + e.y = box.y; + e.width = box.width; + e.height = box.height; + e.border_width = 0; + e.above_sibling = XCB_NONE; + e.override_redirect = overrideRedirect; + xcb_send_event(g_pXWayland->pWM->connection, false, xID, XCB_EVENT_MASK_STRUCTURE_NOTIFY, (const char*)&e); + } + g_pXWayland->pWM->updateClientList(); xcb_flush(g_pXWayland->pWM->connection); |
