diff options
| author | Thomas Ulmer <thomas.ulmer@redflagai.co> | 2026-02-13 09:34:04 -0800 |
|---|---|---|
| committer | Thomas Ulmer <thomas.ulmer@redflagai.co> | 2026-02-13 09:34:04 -0800 |
| commit | 8085a92b7b8ac14424913777fd4355fa153a94a3 (patch) | |
| tree | 3529b64309bfb9ba791f0bf0e501647249c9e5a1 /tree/src/dwm/dwm-6.6/dwm.c | |
| parent | f56506908110a82b369780a5a7cfc07cc7ede850 (diff) | |
dwm redisable focus follows mouse
Diffstat (limited to 'tree/src/dwm/dwm-6.6/dwm.c')
| -rw-r--r-- | tree/src/dwm/dwm-6.6/dwm.c | 46 |
1 files changed, 26 insertions, 20 deletions
diff --git a/tree/src/dwm/dwm-6.6/dwm.c b/tree/src/dwm/dwm-6.6/dwm.c index 80cf56f..b51fd0d 100644 --- a/tree/src/dwm/dwm-6.6/dwm.c +++ b/tree/src/dwm/dwm-6.6/dwm.c @@ -168,7 +168,9 @@ static void detachstack(Client *c); static Monitor *dirtomon(int dir); static void drawbar(Monitor *m); static void drawbars(void); -static void enternotify(XEvent *e); +/* + * static void enternotify(XEvent *e); + */ static void expose(XEvent *e); static void focus(Client *c); static void focusin(XEvent *e); @@ -257,7 +259,9 @@ static void (*handler[LASTEvent]) (XEvent *) = { [ConfigureRequest] = configurerequest, [ConfigureNotify] = configurenotify, [DestroyNotify] = destroynotify, - [EnterNotify] = enternotify, + /* + * [EnterNotify] = enternotify, + */ [Expose] = expose, [FocusIn] = focusin, [KeyPress] = keypress, @@ -823,24 +827,26 @@ drawbars(void) drawbar(m); } -void -enternotify(XEvent *e) -{ - Client *c; - Monitor *m; - XCrossingEvent *ev = &e->xcrossing; - - if ((ev->mode != NotifyNormal || ev->detail == NotifyInferior) && ev->window != root) - return; - c = wintoclient(ev->window); - m = c ? c->mon : wintomon(ev->window); - if (m != selmon) { - unfocus(selmon->sel, 1); - selmon = m; - } else if (!c || c == selmon->sel) - return; - focus(c); -} +/* + * void + * enternotify(XEvent *e) + * { + * Client *c; + * Monitor *m; + * XCrossingEvent *ev = &e->xcrossing; + * + * if ((ev->mode != NotifyNormal || ev->detail == NotifyInferior) && ev->window != root) + * return; + * c = wintoclient(ev->window); + * m = c ? c->mon : wintomon(ev->window); + * if (m != selmon) { + * unfocus(selmon->sel, 1); + * selmon = m; + * } else if (!c || c == selmon->sel) + * return; + * focus(c); + * } + */ void expose(XEvent *e) |
