if (winfocus == NULL || winfocus == win)
winfocus = TAILQ_NEXT(cur_focus, entry);
done:
if (winfocus == NULL || winfocus == win)
winfocus = TAILQ_NEXT(cur_focus, entry);
done:
- if (winfocus == winlostfocus || winfocus == NULL)
+ if (winfocus == winlostfocus || winfocus == NULL) {
+ /* update the bar so that title/class/name will be cleared. */
+ if (window_name_enabled || title_name_enabled || title_class_enabled)
+ bar_update();
+
struct ws_win *cur_focus = NULL;
struct ws_win_list *wl = NULL;
struct workspace *ws = NULL;
struct ws_win *cur_focus = NULL;
struct ws_win_list *wl = NULL;
struct workspace *ws = NULL;
- TAILQ_FOREACH_REVERSE(winfocus, wl, ws_win_list, entry)
+ while (winfocus != cur_focus) {
+ if (winfocus == NULL)
+ winfocus = TAILQ_LAST(wl, ws_win_list);
- if (winfocus == winlostfocus || winfocus == NULL)
+ if (winfocus == winlostfocus || winfocus == NULL) {
+ /* update the bar so that title/class/name will be cleared. */
+ if (window_name_enabled || title_name_enabled || title_class_enabled)
+ bar_update();
+
unmap_window(win);
TAILQ_REMOVE(&ws->winlist, win, entry);
TAILQ_INSERT_TAIL(&nws->winlist, win, entry);
unmap_window(win);
TAILQ_REMOVE(&ws->winlist, win, entry);
TAILQ_INSERT_TAIL(&nws->winlist, win, entry);
long mask;
XGetWMNormalHints(display, win->id, &win->sh, &mask);
fprintf(stderr, "normal hints: flag 0x%x\n", win->sh.flags);
long mask;
XGetWMNormalHints(display, win->id, &win->sh, &mask);
fprintf(stderr, "normal hints: flag 0x%x\n", win->sh.flags);
XMoveResizeWindow(display, win->id,
win->g.x, win->g.y, win->g.w, win->g.h);
#endif
XMoveResizeWindow(display, win->id,
win->g.x, win->g.y, win->g.w, win->g.h);
#endif