From 0f67580aab115e9667650d52104e3ea3a5dfe20b Mon Sep 17 00:00:00 2001 From: Kirill Primak Date: Thu, 22 Jun 2023 15:05:34 +0300 Subject: compositor: introduce wlr_surface_set_role_object() --- xwayland/shell.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'xwayland') diff --git a/xwayland/shell.c b/xwayland/shell.c index 8d34ea04..d362cb7d 100644 --- a/xwayland/shell.c +++ b/xwayland/shell.c @@ -111,7 +111,7 @@ static void shell_handle_get_xwayland_surface(struct wl_client *client, return; } - if (!wlr_surface_set_role(surface, &xwl_surface_role, xwl_surface, + if (!wlr_surface_set_role(surface, &xwl_surface_role, shell_resource, XWAYLAND_SHELL_V1_ERROR_ROLE)) { free(xwl_surface); return; @@ -131,6 +131,8 @@ static void shell_handle_get_xwayland_surface(struct wl_client *client, wl_resource_set_implementation(xwl_surface->resource, &xwl_surface_impl, xwl_surface, xwl_surface_handle_resource_destroy); + wlr_surface_set_role_object(surface, xwl_surface); + wl_list_insert(&shell->surfaces, &xwl_surface->link); xwl_surface->surface_destroy.notify = xwl_surface_handle_surface_destroy; -- cgit v1.2.3