From fee19f79bb41a9f90c25b3470ec2806be7293607 Mon Sep 17 00:00:00 2001 From: Daniel Eklöf Date: Mon, 2 Jan 2023 12:37:02 +0100 Subject: main: implement layer_surface::closed() event MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Destroy the surface, and clear the ‘configured’ flag. Note that we need to take care we don’t reference a destroyed output object; if the compositor destroyed the output before calling the closed() event, the ‘data’ argument will be an invalid pointer. Since removing the output global _also_ destroys the surface, we can handle this by looping all known output globals, and explicitly destroy the surface if we find a match. If we don’t find a match, that means the output has already been destroyed, and we don’t have to do anything at all. --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'CHANGELOG.md') diff --git a/CHANGELOG.md b/CHANGELOG.md index 57de9c6..9fb490f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,10 @@ ### Deprecated ### Removed ### Fixed + +* Respect the `layer_surface::closed()` event. + + ### Security ### Contributors -- cgit v1.2.3