]> git.sur5r.net Git - i3/i3/blobdiff - src/con.c
Merge branch 'master' into next
[i3/i3] / src / con.c
index 8ecc2401d197a80417c4c0ae2f71f2a03489b72b..7b5cc499468e5594f463a726b3a4864ee832e281 100644 (file)
--- a/src/con.c
+++ b/src/con.c
@@ -1061,12 +1061,10 @@ static void con_on_remove_child(Con *con) {
 
     /* For workspaces, close them only if they're not visible anymore */
     if (con->type == CT_WORKSPACE) {
-        int children = con_num_children(con);
-        if (children == 0 && !workspace_is_visible(con)) {
+        if (TAILQ_EMPTY(&(con->focus_head)) && !workspace_is_visible(con)) {
             LOG("Closing old workspace (%p / %s), it is empty\n", con, con->name);
             tree_close(con, DONT_KILL_WINDOW, false, false);
             ipc_send_event("workspace", I3_IPC_EVENT_WORKSPACE, "{\"change\":\"empty\"}");
-            ewmh_update_workarea();
         }
         return;
     }