sway

i3-compatible Wayland compositor
git clone https://git.awy.one/sway
Log | Files | Refs | README | LICENSE

commit 29a535aae4ff631aced5753b45ef32a5f1b342dc
parent 36e48fcf8db273a7d16356248f67aadb27d58ee1
Author: Aleksa Sarai <cyphar@cyphar.com>
Date:   Mon, 26 Dec 2016 19:23:07 +1100

sway: extensions: only unlock if lock_surfaces.length == 0

When destroying lock surfaces, we really should only unlock a
desktop_shell if the set of lock surfaces has dropped to zero (since
callers need to do a set_lock_surface for every output).

Signed-off-by: Aleksa Sarai <cyphar@cyphar.com>

Diffstat:
Msway/extensions.c | 4+++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/sway/extensions.c b/sway/extensions.c @@ -65,10 +65,12 @@ void lock_surface_destructor(struct wl_resource *resource) { if (surface == resource) { list_del(desktop_shell.lock_surfaces, i); arrange_windows(&root_container, -1, -1); - desktop_shell.is_locked = false; break; } } + if (desktop_shell.lock_surfaces->length == 0) { + desktop_shell.is_locked = false; + } } static void set_background(struct wl_client *client, struct wl_resource *resource,