mirror of
https://github.com/tmux/tmux.git
synced 2025-04-19 10:48:47 +00:00
Do not redraw or update mode if nothing has changed.
This commit is contained in:
parent
aebeeec1e9
commit
21a39c997b
@ -434,7 +434,11 @@ screen_redraw_screen(struct client *c)
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
flags = screen_redraw_update(c, c->flags);
|
flags = screen_redraw_update(c, c->flags);
|
||||||
|
if ((flags & CLIENT_ALLREDRAWFLAGS) == 0)
|
||||||
|
return;
|
||||||
|
|
||||||
screen_redraw_set_context(c, &ctx);
|
screen_redraw_set_context(c, &ctx);
|
||||||
|
tty_update_mode(&c->tty, c->tty.mode, NULL);
|
||||||
tty_sync_start(&c->tty);
|
tty_sync_start(&c->tty);
|
||||||
|
|
||||||
if (flags & (CLIENT_REDRAWWINDOW|CLIENT_REDRAWBORDERS)) {
|
if (flags & (CLIENT_REDRAWWINDOW|CLIENT_REDRAWBORDERS)) {
|
||||||
@ -470,6 +474,7 @@ screen_redraw_pane(struct client *c, struct window_pane *wp)
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
screen_redraw_set_context(c, &ctx);
|
screen_redraw_set_context(c, &ctx);
|
||||||
|
tty_update_mode(&c->tty, c->tty.mode, NULL);
|
||||||
tty_sync_start(&c->tty);
|
tty_sync_start(&c->tty);
|
||||||
|
|
||||||
screen_redraw_draw_pane(&ctx, wp);
|
screen_redraw_draw_pane(&ctx, wp);
|
||||||
|
@ -296,7 +296,9 @@ server_client_lost(struct client *c)
|
|||||||
if (c->flags & CLIENT_TERMINAL)
|
if (c->flags & CLIENT_TERMINAL)
|
||||||
tty_free(&c->tty);
|
tty_free(&c->tty);
|
||||||
free(c->ttyname);
|
free(c->ttyname);
|
||||||
|
|
||||||
free(c->term_name);
|
free(c->term_name);
|
||||||
|
free(c->term_type);
|
||||||
|
|
||||||
status_free(c);
|
status_free(c);
|
||||||
|
|
||||||
@ -1780,7 +1782,6 @@ server_client_check_redraw(struct client *c)
|
|||||||
if (!redraw)
|
if (!redraw)
|
||||||
continue;
|
continue;
|
||||||
log_debug("%s: redrawing pane %%%u", __func__, wp->id);
|
log_debug("%s: redrawing pane %%%u", __func__, wp->id);
|
||||||
tty_update_mode(tty, mode, NULL);
|
|
||||||
screen_redraw_pane(c, wp);
|
screen_redraw_pane(c, wp);
|
||||||
}
|
}
|
||||||
c->redraw_panes = 0;
|
c->redraw_panes = 0;
|
||||||
@ -1788,7 +1789,6 @@ server_client_check_redraw(struct client *c)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (c->flags & CLIENT_ALLREDRAWFLAGS) {
|
if (c->flags & CLIENT_ALLREDRAWFLAGS) {
|
||||||
tty_update_mode(tty, mode, NULL);
|
|
||||||
if (options_get_number(s->options, "set-titles"))
|
if (options_get_number(s->options, "set-titles"))
|
||||||
server_client_set_title(c);
|
server_client_set_title(c);
|
||||||
screen_redraw_screen(c);
|
screen_redraw_screen(c);
|
||||||
|
Loading…
Reference in New Issue
Block a user