From ca52808cf5d1928a9a8f263c4c3210e83d80391c Mon Sep 17 00:00:00 2001 From: Abhinav Date: Tue, 24 Jun 2025 16:59:45 +0100 Subject: fix scratchpad focused on toggle off scratchpad now is out of focus when is toggled off so no problems where you accidentaly close it --- src/sxwm.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/sxwm.c') diff --git a/src/sxwm.c b/src/sxwm.c index 8aa7bd8..b1ce613 100644 --- a/src/sxwm.c +++ b/src/sxwm.c @@ -2494,6 +2494,9 @@ void toggle_scratchpad(int n) if (scratchpads[n].enabled) { XUnmapWindow(dpy, scratchpads[n].client->win); scratchpads[n].enabled = False; + focus_prev(); + send_wm_take_focus(focused->win); + update_borders(); } else { XMapWindow(dpy, scratchpads[n].client->win); -- cgit v1.2.3