Got questions, comments, patches, etc.?
Contact Jason Woofenden
gitweb
/
spectrwm.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix height_shrink key binding; use .Xr for xprop(1).
[spectrwm.git]
/
scrotwm.c
diff --git
a/scrotwm.c
b/scrotwm.c
index
658696b
..
5757fc3
100644
(file)
--- a/
scrotwm.c
+++ b/
scrotwm.c
@@
-1485,6
+1485,13
@@
bar_update(void)
}
void
}
void
+bar_check_opts(void)
+{
+ if (title_class_enabled || title_name_enabled || window_name_enabled)
+ bar_update();
+}
+
+void
bar_signal(int sig)
{
bar_alarm = 1;
bar_signal(int sig)
{
bar_alarm = 1;
@@
-2215,8
+2222,7
@@
focus_win(struct ws_win *win)
PropModeReplace, (unsigned char *)&win->id,1);
}
PropModeReplace, (unsigned char *)&win->id,1);
}
- if (window_name_enabled || title_class_enabled || title_name_enabled)
- bar_update();
+ bar_check_opts();
}
void
}
void
@@
-2532,15
+2538,8
@@
focus_prev(struct ws_win *win)
winfocus = TAILQ_LAST(wl, ws_win_list);
if (winfocus == NULL || winfocus == win)
winfocus = TAILQ_NEXT(cur_focus, entry);
winfocus = TAILQ_LAST(wl, ws_win_list);
if (winfocus == NULL || winfocus == win)
winfocus = TAILQ_NEXT(cur_focus, entry);
-done:
- 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();
- return;
- }
+done:
focus_magic(winfocus);
}
focus_magic(winfocus);
}
@@
-2644,14
+2643,6
@@
focus(struct swm_region *r, union arg *args)
default:
return;
}
default:
return;
}
- 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();
-
- return;
- }
focus_magic(winfocus);
}
focus_magic(winfocus);
}
@@
-5997,8
+5988,11
@@
focus_magic(struct ws_win *win)
{
DNPRINTF(SWM_D_FOCUS, "focus_magic: window: 0x%lx\n", WINID(win));
{
DNPRINTF(SWM_D_FOCUS, "focus_magic: window: 0x%lx\n", WINID(win));
- if (win == NULL)
+ if (win == NULL) {
+ /* if there are no windows clear the status-bar */
+ bar_check_opts();
return;
return;
+ }
if (win->child_trans) {
/* win = parent & has a transient so focus on that */
if (win->child_trans) {
/* win = parent & has a transient so focus on that */
@@
-6007,7
+6001,7
@@
focus_magic(struct ws_win *win)
if (win->child_trans->take_focus)
client_msg(win, takefocus);
} else {
if (win->child_trans->take_focus)
client_msg(win, takefocus);
} else {
- /* make sure transient hasn't dissapeared */
+ /* make sure transient hasn't disappeared */
if (validate_win(win->child_trans) == 0) {
focus_win(win->child_trans);
if (win->child_trans->take_focus)
if (validate_win(win->child_trans) == 0) {
focus_win(win->child_trans);
if (win->child_trans->take_focus)