X-Git-Url: https://git.xinqibao.xyz/dwm.git/blobdiff_plain/dee5ea23358ec0a9684265dc8cb1d2e4d56e9b84..1e051d71f509ce0c658170e936896b58b9065f90:/event.c diff --git a/event.c b/event.c index 20c1533..20ab599 100644 --- a/event.c +++ b/event.c @@ -236,7 +236,7 @@ enternotify(XEvent *e) { issel = True; XSetInputFocus(dpy, root, RevertToPointerRoot, CurrentTime); if(sel) - XSetWindowBorder(dpy, sel->win, dc.sel[ColBorder]); + focus(sel); } } @@ -273,9 +273,9 @@ leavenotify(XEvent *e) { XCrossingEvent *ev = &e->xcrossing; if((ev->window == root) && !ev->same_screen) { - issel = False; if(sel) - XSetWindowBorder(dpy, sel->win, dc.norm[ColBorder]); + focus(NULL); + issel = False; } }