From cddbbd8bd68a7e7cbe10237295d515ca28d41a00 Mon Sep 17 00:00:00 2001 From: DreamMaoMao <2523610504@qq.com> Date: Mon, 22 Sep 2025 11:57:52 +0800 Subject: [PATCH] fix: miss re judge the border corler of old mon sel client after change focus mon --- src/dispatch/bind_define.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/dispatch/bind_define.h b/src/dispatch/bind_define.h index 5ce425f..855f1c7 100644 --- a/src/dispatch/bind_define.h +++ b/src/dispatch/bind_define.h @@ -131,7 +131,7 @@ void toggle_trackpad_enable(const Arg *arg) { } void focusmon(const Arg *arg) { - Client *c; + Client *c, *old_selmon_sel; Monitor *m = NULL; if (arg->i != UNDIR) { @@ -152,6 +152,7 @@ void focusmon(const Arg *arg) { if (!m || !m->wlr_output->enabled) return; + old_selmon_sel = selmon->sel; selmon = m; warp_cursor_to_selmon(selmon); c = focustop(selmon); @@ -161,6 +162,10 @@ void focusmon(const Arg *arg) { wlr_seat_keyboard_notify_clear_focus(seat); } else focusclient(c, 1); + + if (old_selmon_sel) { + setborder_color(old_selmon_sel); + } } void // 17