diff options
author | 2015-05-08 16:18:04 +0000 | |
---|---|---|
committer | 2015-05-08 16:18:04 +0000 | |
commit | 6c01012e1b2514797b55a5c7785e5a5f3e69fa71 (patch) | |
tree | 538b15a52228357f38d4884982b1877c45894fa8 /usr.bin/tmux/cmd-send-keys.c | |
parent | Remove some stuff that accidentally ended up here from portable, and (diff) | |
download | wireguard-openbsd-6c01012e1b2514797b55a5c7785e5a5f3e69fa71.tar.xz wireguard-openbsd-6c01012e1b2514797b55a5c7785e5a5f3e69fa71.zip |
Move input parser structs into input.c (removing fairly useless
saved_cursor_[xy] formats as a side-effect).
Diffstat (limited to 'usr.bin/tmux/cmd-send-keys.c')
-rw-r--r-- | usr.bin/tmux/cmd-send-keys.c | 20 |
1 files changed, 3 insertions, 17 deletions
diff --git a/usr.bin/tmux/cmd-send-keys.c b/usr.bin/tmux/cmd-send-keys.c index 99b574f9d15..fefa6169f72 100644 --- a/usr.bin/tmux/cmd-send-keys.c +++ b/usr.bin/tmux/cmd-send-keys.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cmd-send-keys.c,v 1.19 2015/04/19 21:34:21 nicm Exp $ */ +/* $OpenBSD: cmd-send-keys.c,v 1.20 2015/05/08 16:18:04 nicm Exp $ */ /* * Copyright (c) 2008 Nicholas Marriott <nicm@users.sourceforge.net> @@ -52,7 +52,6 @@ cmd_send_keys_exec(struct cmd *self, struct cmd_q *cmdq) struct mouse_event *m = &cmdq->item->mouse; struct window_pane *wp; struct session *s; - struct input_ctx *ictx; const u_char *str; int i, key; @@ -78,21 +77,8 @@ cmd_send_keys_exec(struct cmd *self, struct cmd_q *cmdq) return (CMD_RETURN_NORMAL); } - if (args_has(args, 'R')) { - ictx = &wp->ictx; - - memcpy(&ictx->cell, &grid_default_cell, sizeof ictx->cell); - memcpy(&ictx->old_cell, &ictx->cell, sizeof ictx->old_cell); - ictx->old_cx = 0; - ictx->old_cy = 0; - - if (wp->mode == NULL) - screen_write_start(&ictx->ctx, wp, &wp->base); - else - screen_write_start(&ictx->ctx, NULL, &wp->base); - screen_write_reset(&ictx->ctx); - screen_write_stop(&ictx->ctx); - } + if (args_has(args, 'R')) + input_reset(wp); for (i = 0; i < args->argc; i++) { str = args->argv[i]; |