Files
absinthe/src/xdg-decoration.c
T

26 lines
664 B
C
Raw Normal View History

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