aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicholas Marriott <nicholas.marriott@gmail.com>2018-09-11 18:34:53 +0100
committerNicholas Marriott <nicholas.marriott@gmail.com>2018-09-11 18:34:53 +0100
commit3fa538181b1e1fb4c9414f49013a3e5839c2e2cb (patch)
tree484e0cc59e4367dabd849036db3f12be01d87a68
parent84df87011c0cdf642209ed30bae5b37fb1889ae7 (diff)
downloadrtmux-3fa538181b1e1fb4c9414f49013a3e5839c2e2cb.tar.gz
rtmux-3fa538181b1e1fb4c9414f49013a3e5839c2e2cb.tar.bz2
rtmux-3fa538181b1e1fb4c9414f49013a3e5839c2e2cb.zip
Restore window_pane_visible for drawing panes and borders, fixes issue
1458 reported by Felix Rosencrantz, problem located by Avi Halachmi.
-rw-r--r--screen-redraw.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/screen-redraw.c b/screen-redraw.c
index 1f51e743..a10acd97 100644
--- a/screen-redraw.c
+++ b/screen-redraw.c
@@ -104,6 +104,8 @@ screen_redraw_cell_border(struct client *c, u_int px, u_int py)
/* Check all the panes. */
TAILQ_FOREACH(wp, &w->panes, entry) {
+ if (!window_pane_visible(wp))
+ continue;
if ((retval = screen_redraw_cell_border1(wp, px, py)) != -1)
return (!!retval);
}
@@ -128,6 +130,9 @@ screen_redraw_check_cell(struct client *c, u_int px, u_int py, int pane_status,
if (pane_status != CELL_STATUS_OFF) {
TAILQ_FOREACH(wp, &w->panes, entry) {
+ if (!window_pane_visible(wp))
+ continue;
+
if (pane_status == CELL_STATUS_TOP)
line = wp->yoff - 1;
else
@@ -140,6 +145,8 @@ screen_redraw_check_cell(struct client *c, u_int px, u_int py, int pane_status,
}
TAILQ_FOREACH(wp, &w->panes, entry) {
+ if (!window_pane_visible(wp))
+ continue;
*wpp = wp;
/* If outside the pane and its border, skip it. */
@@ -325,6 +332,8 @@ screen_redraw_draw_pane_status(struct screen_redraw_ctx *ctx)
log_debug("%s: %s @%u", __func__, c->name, w->id);
TAILQ_FOREACH(wp, &w->panes, entry) {
+ if (!window_pane_visible(wp))
+ continue;
s = &wp->status_screen;
size = wp->status_size;
@@ -456,7 +465,7 @@ screen_redraw_pane(struct client *c, struct window_pane *wp)
{
struct screen_redraw_ctx ctx;
- if (wp->layout_cell == NULL)
+ if (!window_pane_visible(wp))
return;
screen_redraw_set_context(c, &ctx);
@@ -545,7 +554,7 @@ screen_redraw_draw_panes(struct screen_redraw_ctx *ctx)
log_debug("%s: %s @%u", __func__, c->name, w->id);
TAILQ_FOREACH(wp, &w->panes, entry) {
- if (wp->layout_cell == NULL)
+ if (!window_pane_visible(wp))
continue;
screen_redraw_draw_pane(ctx, wp);
if (c->flags & CLIENT_IDENTIFY)