aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/nvim/terminal.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/nvim/terminal.c b/src/nvim/terminal.c
index d97c24dcf7..6add541ad4 100644
--- a/src/nvim/terminal.c
+++ b/src/nvim/terminal.c
@@ -1295,6 +1295,12 @@ static bool send_mouse_event(Terminal *term, int c)
return mouse_win == curwin;
}
+ // ignore left release action if it was not proccessed above
+ // to prevent leaving Terminal mode after entering to it using a mouse
+ if (c == K_LEFTRELEASE && mouse_win->w_buffer->terminal == term) {
+ return false;
+ }
+
end:
ins_char_typebuf(c);
return true;