]> git.sur5r.net Git - i3/i3/commitdiff
Bugfix: The last commit also needs to be applied to some other pieces of code (Thanks...
authorMichael Stapelberg <michael@stapelberg.de>
Tue, 30 Mar 2010 06:12:06 +0000 (08:12 +0200)
committerMichael Stapelberg <michael@stapelberg.de>
Tue, 30 Mar 2010 06:12:06 +0000 (08:12 +0200)
src/handlers.c

index 67b377f8ccf9f4e6aa3015cf597ffa2e61bfe12a..d9fa0d2d48ad1e2db99688aa5742620b43203000 100644 (file)
@@ -636,6 +636,9 @@ int handle_windowname_change(void *data, xcb_connection_t *conn, uint8_t state,
         if (client->dock)
                 return 1;
 
+        if (!workspace_is_visible(client->workspace))
+                return 1;
+
         int mode = container_mode(client->container, true);
         if (mode == MODE_STACK || mode == MODE_TABBED)
                 render_container(conn, client->container);
@@ -702,6 +705,9 @@ int handle_windowname_change_legacy(void *data, xcb_connection_t *conn, uint8_t
         if (client->dock)
                 return 1;
 
+        if (!workspace_is_visible(client->workspace))
+                return 1;
+
         if (client->container != NULL &&
             (client->container->mode == MODE_STACK ||
              client->container->mode == MODE_TABBED))
@@ -1001,7 +1007,6 @@ int handle_hints(void *data, xcb_connection_t *conn, uint8_t state, xcb_window_t
         LOG("Urgency flag changed to %d\n", client->urgent);
 
         workspace_update_urgent_flag(client->workspace);
-        redecorate_window(conn, client);
 
         /* If the workspace this client is on is not visible, we need to redraw
          * the workspace bar */
@@ -1009,6 +1014,8 @@ int handle_hints(void *data, xcb_connection_t *conn, uint8_t state, xcb_window_t
                 Output *output = client->workspace->output;
                 render_workspace(conn, output, output->current_workspace);
                 xcb_flush(conn);
+        } else {
+                redecorate_window(conn, client);
         }
 
         return 1;