Files
absinthe/src/xdg-decoration.c
T

22 lines
714 B
C
Raw Normal View History

2026-01-04 18:07:28 +07:00
#include <wayland-server-core.h>
#include "types.h"
void xdg_decoration_request_mode(struct wl_listener *listener, void *data)
{
2026-04-26 14:31:03 +07:00
UNUSED(data);
2026-04-25 14:09:14 +07:00
struct absinthe_toplevel *toplevel = wl_container_of(listener, toplevel, decoration_request_mode);
if (toplevel->toplevel.xdg->base->initialized)
wlr_xdg_toplevel_decoration_v1_set_mode(toplevel->decoration,
WLR_XDG_TOPLEVEL_DECORATION_V1_MODE_SERVER_SIDE);
2026-01-04 18:07:28 +07:00
}
void xdg_decoration_destroy(struct wl_listener *listener, void *data)
{
2026-04-26 14:31:03 +07:00
UNUSED(data);
2026-04-25 14:09:14 +07:00
struct absinthe_toplevel *toplevel = wl_container_of(listener, toplevel, decoration_destroy);
2026-01-04 18:07:28 +07:00
2026-04-25 14:09:14 +07:00
wl_list_remove(&toplevel->decoration_request_mode.link);
wl_list_remove(&toplevel->decoration_destroy.link);
2026-01-04 18:07:28 +07:00
}