about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--client.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/client.c b/client.c
index 74fafbc..6c9581d 100644
--- a/client.c
+++ b/client.c
@@ -211,7 +211,8 @@ client_setactive(struct client_ctx *cc, int fg)
 
 	if (fg) {
 		XInstallColormap(X_Dpy, cc->colormap);
-		if (cc->flags & CLIENT_INPUT) {
+		if ((cc->flags & CLIENT_INPUT) ||
+		    ((cc->xproto & _WM_TAKE_FOCUS) == 0)) {
 			XSetInputFocus(X_Dpy, cc->win,
 			    RevertToPointerRoot, CurrentTime);
 		}