diff options
author | Thomas Adam <thomas@xteddy.org> | 2014-04-23 11:26:11 +0100 |
---|---|---|
committer | Thomas Adam <thomas@xteddy.org> | 2014-04-23 11:26:11 +0100 |
commit | 953c3ef47a1933d38308075c1bacc7ea8d38301b (patch) | |
tree | 6484bdd51ecedbb5888717db271c151257ec87f5 /server-window.c | |
parent | 12e9c974fadc5ed6f0e7db10c40d5a0d55e0da8a (diff) | |
parent | 64613b9d411a7c76a50a2f9c66df345f082fce25 (diff) | |
download | rtmux-953c3ef47a1933d38308075c1bacc7ea8d38301b.tar.gz rtmux-953c3ef47a1933d38308075c1bacc7ea8d38301b.tar.bz2 rtmux-953c3ef47a1933d38308075c1bacc7ea8d38301b.zip |
Merge branch 'obsd-master'
Conflicts:
Makefile
tmux.1
window.c
Diffstat (limited to 'server-window.c')
-rw-r--r-- | server-window.c | 55 |
1 files changed, 4 insertions, 51 deletions
diff --git a/server-window.c b/server-window.c index 900060b5..61be1b80 100644 --- a/server-window.c +++ b/server-window.c @@ -27,19 +27,16 @@ int server_window_check_bell(struct session *, struct winlink *); int server_window_check_activity(struct session *, struct winlink *); int server_window_check_silence(struct session *, struct winlink *); -int server_window_check_content( - struct session *, struct winlink *, struct window_pane *); void ring_bell(struct session *); /* Window functions that need to happen every loop. */ void server_window_loop(void) { - struct window *w; - struct winlink *wl; - struct window_pane *wp; - struct session *s; - u_int i; + struct window *w; + struct winlink *wl; + struct session *s; + u_int i; for (i = 0; i < ARRAY_LENGTH(&windows); i++) { w = ARRAY_ITEM(&windows, i); @@ -55,8 +52,6 @@ server_window_loop(void) server_window_check_activity(s, wl) || server_window_check_silence(s, wl)) server_status_session(s); - TAILQ_FOREACH(wp, &w->panes, entry) - server_window_check_content(s, wl, wp); } } } @@ -187,48 +182,6 @@ server_window_check_silence(struct session *s, struct winlink *wl) return (1); } -/* Check for content change in window. */ -int -server_window_check_content( - struct session *s, struct winlink *wl, struct window_pane *wp) -{ - struct client *c; - struct window *w = wl->window; - u_int i; - char *found, *ptr; - - /* Activity flag must be set for new content. */ - if (s->curw->window == w) - w->flags &= ~WINDOW_ACTIVITY; - - if (!(w->flags & WINDOW_ACTIVITY) || wl->flags & WINLINK_CONTENT) - return (0); - if (s->curw == wl && !(s->flags & SESSION_UNATTACHED)) - return (0); - - ptr = options_get_string(&w->options, "monitor-content"); - if (ptr == NULL || *ptr == '\0') - return (0); - if ((found = window_pane_search(wp, ptr, NULL)) == NULL) - return (0); - free(found); - - if (options_get_number(&s->options, "bell-on-alert")) - ring_bell(s); - wl->flags |= WINLINK_CONTENT; - - if (options_get_number(&s->options, "visual-content")) { - for (i = 0; i < ARRAY_LENGTH(&clients); i++) { - c = ARRAY_ITEM(&clients, i); - if (c == NULL || c->session != s) - continue; - status_message_set(c, "Content in window %u", wl->idx); - } - } - - return (1); -} - /* Ring terminal bell. */ void ring_bell(struct session *s) |