diff options
author | nicm <nicm> | 2018-08-19 16:45:03 +0000 |
---|---|---|
committer | nicm <nicm> | 2018-08-19 16:45:03 +0000 |
commit | 88327c7698fc45a16d1a5235d71a078d419febb4 (patch) | |
tree | 174a1dad71f2dd7a08e0d181b48317c134c454dc /status.c | |
parent | bd2896b65e8fd205e3207ed70558d9ebfd106909 (diff) | |
download | rtmux-88327c7698fc45a16d1a5235d71a078d419febb4.tar.gz rtmux-88327c7698fc45a16d1a5235d71a078d419febb4.tar.bz2 rtmux-88327c7698fc45a16d1a5235d71a078d419febb4.zip |
Add a client redraw-window flag instead of the redraw-all flag and for
all just use the three flags together (window, borders, status).
Diffstat (limited to 'status.c')
-rw-r--r-- | status.c | 24 |
1 files changed, 12 insertions, 12 deletions
@@ -157,7 +157,7 @@ status_timer_callback(__unused int fd, __unused short events, void *arg) return; if (c->message_string == NULL && c->prompt_string == NULL) - c->flags |= CLIENT_STATUS; + c->flags |= CLIENT_REDRAWSTATUS; timerclear(&tv); tv.tv_sec = options_get_number(s->options, "status-interval"); @@ -615,7 +615,7 @@ status_message_set(struct client *c, const char *fmt, ...) } c->tty.flags |= (TTY_NOCURSOR|TTY_FREEZE); - c->flags |= CLIENT_STATUS; + c->flags |= CLIENT_REDRAWSTATUS; } /* Clear status line message. */ @@ -630,7 +630,7 @@ status_message_clear(struct client *c) if (c->prompt_string == NULL) c->tty.flags &= ~(TTY_NOCURSOR|TTY_FREEZE); - c->flags |= CLIENT_REDRAW; /* screen was frozen and may have changed */ + c->flags |= CLIENT_ALLREDRAWFLAGS; /* was frozen and may have changed */ screen_reinit(&c->status.status); } @@ -734,7 +734,7 @@ status_prompt_set(struct client *c, const char *msg, const char *input, if (~flags & PROMPT_INCREMENTAL) c->tty.flags |= (TTY_NOCURSOR|TTY_FREEZE); - c->flags |= CLIENT_STATUS; + c->flags |= CLIENT_REDRAWSTATUS; if ((flags & PROMPT_INCREMENTAL) && *tmp != '\0') { xasprintf(&cp, "=%s", tmp); @@ -763,7 +763,7 @@ status_prompt_clear(struct client *c) c->prompt_buffer = NULL; c->tty.flags &= ~(TTY_NOCURSOR|TTY_FREEZE); - c->flags |= CLIENT_REDRAW; /* screen was frozen and may have changed */ + c->flags |= CLIENT_ALLREDRAWFLAGS; /* was frozen and may have changed */ screen_reinit(&c->status.status); } @@ -791,7 +791,7 @@ status_prompt_update(struct client *c, const char *msg, const char *input) c->prompt_hindex = 0; - c->flags |= CLIENT_STATUS; + c->flags |= CLIENT_REDRAWSTATUS; free(tmp); format_free(ft); @@ -938,7 +938,7 @@ status_prompt_translate_key(struct client *c, key_code key, key_code *new_key) return (1); case '\033': /* Escape */ c->prompt_mode = PROMPT_COMMAND; - c->flags |= CLIENT_STATUS; + c->flags |= CLIENT_REDRAWSTATUS; return (0); } *new_key = key; @@ -952,17 +952,17 @@ status_prompt_translate_key(struct client *c, key_code key, key_code *new_key) case 's': case 'a': c->prompt_mode = PROMPT_ENTRY; - c->flags |= CLIENT_STATUS; + c->flags |= CLIENT_REDRAWSTATUS; break; /* switch mode and... */ case 'S': c->prompt_mode = PROMPT_ENTRY; - c->flags |= CLIENT_STATUS; + c->flags |= CLIENT_REDRAWSTATUS; *new_key = '\025'; /* C-u */ return (1); case 'i': case '\033': /* Escape */ c->prompt_mode = PROMPT_ENTRY; - c->flags |= CLIENT_STATUS; + c->flags |= CLIENT_REDRAWSTATUS; return (0); } @@ -1357,7 +1357,7 @@ process_key: goto append_key; } - c->flags |= CLIENT_STATUS; + c->flags |= CLIENT_REDRAWSTATUS; return (0); append_key: @@ -1392,7 +1392,7 @@ append_key: } changed: - c->flags |= CLIENT_STATUS; + c->flags |= CLIENT_REDRAWSTATUS; if (c->prompt_flags & PROMPT_INCREMENTAL) { s = utf8_tocstr(c->prompt_buffer); xasprintf(&cp, "%c%s", prefix, s); |