xdg-shell: Require proper object tree destruction

Require all child objects to be destroyed before the parent. In other
words, all popups and surfaces created by one xdg_shell instance needs
to be destroyed before the xdg_shell object, otherwise a protocol error
is raised.

Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
Acked-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
This commit is contained in:
Jonas Ådahl
2015-03-18 16:20:51 +08:00
parent 29612053e5
commit 49d77d20ae
2 changed files with 29 additions and 3 deletions
+3 -3
View File
@@ -49,6 +49,7 @@
<enum name="error">
<entry name="role" value="0" summary="given wl_surface has another role"/>
<entry name="defunct_surfaces" value="1" summary="xdg_shell was destroyed before children"/>
</enum>
<request name="destroy" type="destructor">
@@ -56,9 +57,8 @@
Destroy this xdg_shell object.
Destroying a bound xdg_shell object while there are surfaces
still alive with roles from this interface is illegal and will
result in a protocol error. Make sure to destroy all surfaces
before destroying this object.
still alive created by this xdg_shell object instance is illegal
and will result in a protocol error.
</description>
</request>