summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorProsperousPotato <ProsperousPotato@users.noreply.github.com>2026-01-10 17:26:51 +0000
committerProsperousPotato <ProsperousPotato@users.noreply.github.com>2026-01-10 17:26:51 +0000
commit24c32b885948a012bac3e515c490c8fa2b4a5419 (patch)
tree82525e8610bc0b876ad6b1cb9ff590c1133fcd26
parent55ce25969ed3df255965a0f01fc6b511fb275301 (diff)
warp mouse when switching active window with swapfocus
-rw-r--r--dwm.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/dwm.c b/dwm.c
index f79f9c2..4d549f6 100644
--- a/dwm.c
+++ b/dwm.c
@@ -2062,6 +2062,7 @@ swapfocus()
for(c = selmon->clients; c && c != prevclient; c = c->next) ;
if(c == prevclient)
focus(prevclient);
+ XWarpPointer(dpy, None, selmon->sel->win, 0, 0, 0, 0, selmon->sel->w/2, selmon->sel->h/2);
}
void