fix: skip unmap notifications for unmanaged clients

This commit is contained in:
retoor 2026-02-19 21:48:46 +01:00
parent 527f644a94
commit e0bc89ecdc
5 changed files with 7 additions and 0 deletions

BIN
bin/dwn

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -833,6 +833,7 @@ void client_set_fullscreen(Client *client, bool fullscreen)
XRaiseWindow(dwn->display, client->window);
XSync(dwn->display, False);
} else {
client->flags |= CLIENT_UNMANAGING;
client->flags &= ~CLIENT_FULLSCREEN;
atoms_update_wm_state(client->window, ewmh.NET_WM_STATE_FULLSCREEN, false);
api_emit_window_fullscreen(client->window, false);
@ -855,6 +856,7 @@ void client_set_fullscreen(Client *client, bool fullscreen)
decorations_render(client, true);
client_raise(client);
XSync(dwn->display, False);
client->flags &= ~CLIENT_UNMANAGING;
}
}

View File

@ -335,6 +335,11 @@ static void handle_unmap_notify(XUnmapEvent *ev)
return;
}
if (c->flags & CLIENT_UNMANAGING) {
LOG_DEBUG("handle_unmap_notify: window %lu is being unmanged, skipping unmap", c->window);
return;
}
if (c->workspace != (unsigned int)dwn->current_workspace) {
return;
}