X-Git-Url: https://git.xinqibao.xyz/dwm.git/blobdiff_plain/26157e6973f240a9b5ee407b9d2d5eca9358844f..1b2e149cb407be34be0f2b28b8801dc3224eb5c2:/client.c diff --git a/client.c b/client.c index 8a8a99e..0b5fb2b 100644 --- a/client.c +++ b/client.c @@ -254,6 +254,10 @@ manage(Window w, XWindowAttributes *wa) clients = c; settitle(c); + if(isvisible(c)) { + focus(NULL); + sel = c; + } arrange(NULL); XMapWindow(dpy, c->win); XMapWindow(dpy, c->twin);