From a55a3daae7280350f413bcb7570104480fcbebcd Mon Sep 17 00:00:00 2001 From: Daniel Eklöf Date: Sun, 28 Nov 2021 16:48:30 +0100 Subject: input: regression: special keys don’t reset view and cancel selection MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This fixes an issue where e.g. holding down ctrl would cancel the selection, thus making it impossible to copy text to the clipboard. --- input.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'input.c') diff --git a/input.c b/input.c index f97deb93..0c981376 100644 --- a/input.c +++ b/input.c @@ -1594,8 +1594,10 @@ key_press_release(struct seat *seat, struct terminal *term, uint32_t serial, if (utf8 != buf) free(utf8); - term_reset_view(term); - selection_cancel(term); + if (count > 0) { + term_reset_view(term); + selection_cancel(term); + } maybe_repeat: clock_gettime( -- cgit v1.3