decorations/xdg-deco: advertise xdg-decoration-v1 version 2

References:

https://gitlab.freedesktop.org/wlroots/wlroots/-/merge_requests/5385

https://github.com/swaywm/sway/pull/9171
This commit is contained in:
daniel 2026-05-30 02:25:42 -03:00
parent d5b5b765c7
commit 27459ec19d

View file

@ -6,6 +6,8 @@
#include "labwc.h"
#include "view.h"
#define LAB_XDG_DECORATION_VERSION 2
struct xdg_deco {
struct wlr_xdg_toplevel_decoration_v1 *wlr_xdg_decoration;
enum wlr_xdg_toplevel_decoration_v1_mode client_mode;
@ -118,7 +120,8 @@ void
xdg_server_decoration_init(void)
{
struct wlr_xdg_decoration_manager_v1 *xdg_deco_mgr = NULL;
xdg_deco_mgr = wlr_xdg_decoration_manager_v1_create(server.wl_display);
xdg_deco_mgr = wlr_xdg_decoration_manager_v1_create(server.wl_display,
LAB_XDG_DECORATION_VERSION);
if (!xdg_deco_mgr) {
wlr_log(WLR_ERROR, "unable to create the XDG deco manager");
exit(EXIT_FAILURE);