fix: miss exclude unmap client in focuslast

This commit is contained in:
DreamMaoMao 2025-08-13 12:11:32 +08:00
parent 0bfdb1ab4c
commit e03a27e90e

View file

@ -72,7 +72,8 @@ void focuslast(const Arg *arg) {
wl_list_for_each(c, &fstack, flink) { wl_list_for_each(c, &fstack, flink) {
if (c->iskilling || c->isminied || c->isunglobal || if (c->iskilling || c->isminied || c->isunglobal ||
client_is_unmanaged(c) || client_should_ignore_focus(c)) !client_surface(c)->mapped || client_is_unmanaged(c) ||
client_should_ignore_focus(c))
continue; continue;
if (selmon && !selmon->sel) { if (selmon && !selmon->sel) {
@ -88,7 +89,7 @@ void focuslast(const Arg *arg) {
break; break;
} }
if (!c) if (!c || !client_surface(c)->mapped)
return; return;
if ((int)c->tags > 0) { if ((int)c->tags > 0) {