From 2ef28273b00722cc304c2cf9df28da8c321ad79e Mon Sep 17 00:00:00 2001 From: Karutoh Date: Fri, 5 Jul 2024 13:15:34 -0700 Subject: [PATCH] Fixed Wayland window decoration. --- src/io/Window_Way.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/io/Window_Way.cpp b/src/io/Window_Way.cpp index 0117130..387d1a3 100644 --- a/src/io/Window_Way.cpp +++ b/src/io/Window_Way.cpp @@ -72,6 +72,9 @@ namespace ehs void Window::SurfaceConfigure(void* data, xdg_surface* xdg_surface, UInt_32 serial) { xdg_surface_ack_configure(xdg_surface, serial); + + if (data) + wl_surface_commit(((Window*)data)->wlSurface); } void Window::ShellPing(void* data, xdg_wm_base* shell, UInt_32 serial) @@ -279,7 +282,7 @@ namespace ehs static constexpr xdg_surface_listener surfaceListener = {SurfaceConfigure}; - xdg_surface_add_listener(xdgSurface, &surfaceListener, nullptr); + xdg_surface_add_listener(xdgSurface, &surfaceListener, this); xdgToplevel = xdg_surface_get_toplevel(xdgSurface);