summaryrefslogtreecommitdiffstats
path: root/cmd-clear-history.c
diff options
context:
space:
mode:
authornicm <nicm>2015-08-16 08:57:34 +0000
committernicm <nicm>2015-08-16 08:57:34 +0000
commit58b659a26e3c558614155ba351e7f275f277e4d3 (patch)
tree4a70b9f68a803de0257bfde0a63068d2360c76aa /cmd-clear-history.c
parent46aa92420a4d3af7d273155aabb646d4bc91bb01 (diff)
Come out of copy mode when history is cleared.
Diffstat (limited to 'cmd-clear-history.c')
-rw-r--r--cmd-clear-history.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/cmd-clear-history.c b/cmd-clear-history.c
index e1342880..88dbbcf7 100644
--- a/cmd-clear-history.c
+++ b/cmd-clear-history.c
@@ -45,6 +45,9 @@ cmd_clear_history_exec(struct cmd *self, struct cmd_q *cmdq)
return (CMD_RETURN_ERROR);
gd = wp->base.grid;
+ if (wp->mode == &window_copy_mode)
+ window_pane_reset_mode(wp);
+
grid_move_lines(gd, 0, gd->hsize, gd->sy);
gd->hsize = 0;