mirror of
https://github.com/tmux/tmux.git
synced 2025-09-02 13:37:12 +00:00
Don't redraw status line unless it has actually changed. Stops extraneous
updates between clock/#() changes and doesn't require manual status-interval 0 when no updates are occuring.
This commit is contained in:
12
server.c
12
server.c
@ -1,4 +1,4 @@
|
||||
/* $Id: server.c,v 1.118 2009-02-08 16:26:43 nicm Exp $ */
|
||||
/* $Id: server.c,v 1.119 2009-02-10 00:18:06 nicm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
|
||||
@ -464,7 +464,7 @@ server_check_redraw(struct client *c)
|
||||
{
|
||||
struct session *s;
|
||||
char title[512];
|
||||
int flags;
|
||||
int flags, redraw;
|
||||
|
||||
if (c == NULL || c->session == NULL)
|
||||
return;
|
||||
@ -487,11 +487,13 @@ server_check_redraw(struct client *c)
|
||||
|
||||
if (c->flags & (CLIENT_REDRAW|CLIENT_STATUS)) {
|
||||
if (c->message_string != NULL)
|
||||
status_message_redraw(c);
|
||||
redraw = status_message_redraw(c);
|
||||
else if (c->prompt_string != NULL)
|
||||
status_prompt_redraw(c);
|
||||
redraw = status_prompt_redraw(c);
|
||||
else
|
||||
status_redraw(c);
|
||||
redraw = status_redraw(c);
|
||||
if (!redraw)
|
||||
c->flags &= ~CLIENT_STATUS;
|
||||
}
|
||||
|
||||
if (c->flags & CLIENT_REDRAW) {
|
||||
|
Reference in New Issue
Block a user