From f4c123a963fba68a8e8d82bc5b8b29d3006626e5 Mon Sep 17 00:00:00 2001 From: korei999 Date: Fri, 8 Dec 2023 20:10:46 +0200 Subject: [PATCH] remove unnecessary check --- dwl.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/dwl.c b/dwl.c index cd160ef..45a7c8a 100644 --- a/dwl.c +++ b/dwl.c @@ -1385,7 +1385,7 @@ destroylocksurface(struct wl_listener *listener, void *data) surface = wl_container_of(cur_lock->surfaces.next, surface, link); client_notify_enter(surface->surface, wlr_seat_get_keyboard(seat)); } else if (!locked) { - focusclient(focustop(selmon, 0), 1); + focusclient(focustop(selmon, 0), 1); } else { wlr_seat_keyboard_clear_focus(seat); } @@ -3136,12 +3136,11 @@ togglesticky(const Arg *arg) return; sel->issticky = !sel->issticky; - if (sel->issticky) { + if (sel->issticky) client_set_border_color(sel, mixedcolor); - } else { - client_set_border_color(sel, focuscolor); - if (!VISIBLEON(sel, selmon)) - focusclient(focustop(selmon, 0), 1); + else { + client_set_border_color(sel, focuscolor); + focusclient(focustop(selmon, 0), 1); } arrange(selmon);