diff options
author | nicm <nicm> | 2016-04-29 15:00:48 +0000 |
---|---|---|
committer | nicm <nicm> | 2016-04-29 15:00:48 +0000 |
commit | 0509be07404a4f4626bbdab56d858f657dc68604 (patch) | |
tree | ae0d8196081ac903121f0d2e4ac754a763a3689d /server-client.c | |
parent | 0d84fdd95303a6ed4dcd761425e35f3731b86725 (diff) | |
download | rtmux-0509be07404a4f4626bbdab56d858f657dc68604.tar.gz rtmux-0509be07404a4f4626bbdab56d858f657dc68604.tar.bz2 rtmux-0509be07404a4f4626bbdab56d858f657dc68604.zip |
Add option to include status text in the pane borders. If
pane-border-status is set to "top" or "bottom" (rather than "off"),
every pane has a permanent top or bottom border containing the text from
pane-border-format.
Based on a diff sent long ago by Jonathan Slenders, mostly rewritten and
simplified by me.
Diffstat (limited to 'server-client.c')
-rw-r--r-- | server-client.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/server-client.c b/server-client.c index 9dad52fe..08f48b31 100644 --- a/server-client.c +++ b/server-client.c @@ -921,7 +921,7 @@ server_client_check_redraw(struct client *c) struct session *s = c->session; struct tty *tty = &c->tty; struct window_pane *wp; - int flags, redraw; + int flags, masked, redraw; if (c->flags & (CLIENT_CONTROL|CLIENT_SUSPENDED)) return; @@ -961,15 +961,15 @@ server_client_check_redraw(struct client *c) } } - if (c->flags & CLIENT_BORDERS) { + masked = c->flags & (CLIENT_BORDERS|CLIENT_STATUS); + if (masked != 0) tty_update_mode(tty, tty->mode, NULL); + if (masked == CLIENT_BORDERS) screen_redraw_screen(c, 0, 0, 1); - } - - if (c->flags & CLIENT_STATUS) { - tty_update_mode(tty, tty->mode, NULL); + else if (masked == CLIENT_STATUS) screen_redraw_screen(c, 0, 1, 0); - } + else if (masked != 0) + screen_redraw_screen(c, 0, 1, 1); tty->flags = (tty->flags & ~(TTY_FREEZE|TTY_NOCURSOR)) | flags; tty_update_mode(tty, tty->mode, NULL); |