]> code.delx.au - spectrwm/commitdiff
Kill references before focusing on a new window.
authorTiago Cunha <tcunha@gmx.com>
Sat, 12 May 2012 21:17:22 +0000 (22:17 +0100)
committerTiago Cunha <tcunha@gmx.com>
Tue, 5 Jun 2012 21:30:56 +0000 (22:30 +0100)
Like the other focusing functions, make focus_prev call kill_refs before
trying to focus on a new window. This way, the current window references
are cleared like it should be when the very last window is destroyed.

Otherwise, the status-bar output will contain (while its alarm does not
expire) the class hint of the to be removed window.

spectrwm.c

index 038b1b00ce9413c55c228cf0563fdfb0e3587f0e..1cf254e91f57028a4cafc44e433801d18dbfe5d0 100644 (file)
@@ -2576,6 +2576,7 @@ done:
                        winfocus = TAILQ_FIRST(wl);
        }
 
+       kill_refs(win);
        focus_magic(winfocus);
 }
 
@@ -6178,8 +6179,6 @@ unmanage_window(struct ws_win *win)
 
        TAILQ_REMOVE(&win->ws->winlist, win, entry);
        TAILQ_INSERT_TAIL(&win->ws->unmanagedlist, win, entry);
-
-       kill_refs(win);
 }
 
 void