diff options
author | nicm <nicm> | 2019-05-11 06:34:56 +0000 |
---|---|---|
committer | nicm <nicm> | 2019-05-11 06:34:56 +0000 |
commit | ad27b7decd61d353031aeac5de01d44bcb374f26 (patch) | |
tree | 489a22db4425fcb707d3076ac22cc0af14dad21d | |
parent | d62fd78655b305f4db9b41ff3b5a35b909674d74 (diff) | |
download | rtmux-ad27b7decd61d353031aeac5de01d44bcb374f26.tar.gz rtmux-ad27b7decd61d353031aeac5de01d44bcb374f26.tar.bz2 rtmux-ad27b7decd61d353031aeac5de01d44bcb374f26.zip |
Do not reduce window height by status line height for control mode
clients, from George Nachman.
-rw-r--r-- | resize.c | 5 | ||||
-rw-r--r-- | status.c | 4 |
2 files changed, 5 insertions, 4 deletions
@@ -174,11 +174,12 @@ recalculate_sizes(void) TAILQ_FOREACH(c, &clients, entry) { if (ignore_client_size(c)) continue; - if (c->tty.sy <= status_line_size(c)) + s = c->session; + if (c->tty.sy <= s->statuslines || (c->flags & CLIENT_CONTROL)) c->flags |= CLIENT_STATUSOFF; else c->flags &= ~CLIENT_STATUSOFF; - c->session->attached++; + s->attached++; } /* Walk each window and adjust the size. */ @@ -203,7 +203,7 @@ status_at_line(struct client *c) { struct session *s = c->session; - if (c->flags & CLIENT_STATUSOFF) + if (c->flags & (CLIENT_STATUSOFF|CLIENT_CONTROL)) return (-1); if (s->statusat != 1) return (s->statusat); @@ -216,7 +216,7 @@ status_line_size(struct client *c) { struct session *s = c->session; - if (c->flags & CLIENT_STATUSOFF) + if (c->flags & (CLIENT_STATUSOFF|CLIENT_CONTROL)) return (0); return (s->statuslines); } |