summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2017-08-05 18:02:21 +0200
committerBram Moolenaar <Bram@vim.org>2017-08-05 18:02:21 +0200
commitb9279e73aee44a266c241619db65c645f7db72ee (patch)
tree1418af28315d9a92e7d07b3dd992f0fd14d1553a
parenta9f028103fee253ea8a09e49031011ee3da69ece (diff)
patch 8.0.0870: mouse escape codes sent to terminal unintentionallyv8.0.0870
Problem: Mouse escape codes sent to terminal unintentionally. Solution: Fix libvterm to send mouse codes only when enabled.
-rw-r--r--src/libvterm/src/mouse.c2
-rw-r--r--src/terminal.c1
-rw-r--r--src/version.c2
3 files changed, 4 insertions, 1 deletions
diff --git a/src/libvterm/src/mouse.c b/src/libvterm/src/mouse.c
index ba17aa466f..273bde98e3 100644
--- a/src/libvterm/src/mouse.c
+++ b/src/libvterm/src/mouse.c
@@ -86,6 +86,8 @@ void vterm_mouse_button(VTerm *vt, int button, int pressed, VTermModifier mod)
/* Most of the time we don't get button releases from 4/5 */
if(state->mouse_buttons == old_buttons && button < 4)
return;
+ if (!(state->mouse_flags & MOUSE_WANT_CLICK))
+ return;
if(button < 4) {
output_mouse(state, button-1, pressed, mod, state->mouse_col, state->mouse_row);
diff --git a/src/terminal.c b/src/terminal.c
index b708f3e948..0f5382bacd 100644
--- a/src/terminal.c
+++ b/src/terminal.c
@@ -37,7 +37,6 @@
*
* TODO:
* - MS-Windows: no redraw for 'updatetime' #1915
- * - in bash mouse clicks are inserting characters.
* - mouse scroll: when over other window, scroll that window.
* - add argument to term_wait() for waiting time.
* - For the scrollback buffer store lines in the buffer, only attributes in
diff --git a/src/version.c b/src/version.c
index d1b20b1733..195be511ed 100644
--- a/src/version.c
+++ b/src/version.c
@@ -770,6 +770,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 870,
+/**/
869,
/**/
868,