From 0dc23e380a59fcf8a670273dc65816c2cc6de472 Mon Sep 17 00:00:00 2001 From: Kirill Primak Date: Sat, 15 Oct 2022 20:26:42 +0300 Subject: [PATCH] protocol: add defunct_role_object error This commit adds wl_surface.defunct_role_object error, which has semantics similar to xdg_wm_base.defunct_surfaces error, and is sent when a client destroys a surface while the corresponding role object still exists. Signed-off-by: Kirill Primak --- protocol/wayland.xml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/protocol/wayland.xml b/protocol/wayland.xml index 6589d5e8..a94e85c2 100644 --- a/protocol/wayland.xml +++ b/protocol/wayland.xml @@ -1384,8 +1384,9 @@ that this request gives a role to a wl_surface. Often, this request also creates a new protocol object that represents the role and adds additional functionality to wl_surface. When a - client wants to destroy a wl_surface, they must destroy this 'role - object' before the wl_surface. + client wants to destroy a wl_surface, they must destroy this role + object before the wl_surface, otherwise a defunct_role_object error is + sent. Destroying the role object does not remove the role from the wl_surface, but it may stop the wl_surface from "playing the role". @@ -1405,6 +1406,8 @@ +