]> Dogcows Code - chaz/openbox/blobdiff - openbox/client.c
check for focus before unfocusing
[chaz/openbox] / openbox / client.c
index 68e1e09886d4d6d09aa1de0a047c5af8c9355669..7fca4796bbdb838c6060ed79774b60701c84f327 100644 (file)
@@ -139,7 +139,7 @@ void client_manage_all()
     client_startup_stack_size = 0;
 
     if (focus_new)
-        focus_fallback(FALSE);
+        focus_fallback(Fallback_NoFocus);
 }
 
 void client_manage(Window window)
@@ -312,7 +312,8 @@ void client_unmanage(Client *self)
         }
     }
 
-    focus_fallback(FALSE);
+    if (focus_client == self)
+        client_unfocus(self);
 
     /* remove from its group */
     if (self->group) {
@@ -2080,7 +2081,7 @@ void client_unfocus(Client *self)
 {
     g_assert(focus_client == self);
     g_message("client_unfocus");
-    focus_fallback(FALSE);
+    focus_fallback(Fallback_Unfocusing);
 }
 
 gboolean client_focused(Client *self)
This page took 0.020645 seconds and 4 git commands to generate.