diff options
author | Bram Moolenaar <Bram@vim.org> | 2020-07-09 19:16:35 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2020-07-09 19:16:35 +0200 |
commit | ae97b94176062d30ea8c68bb83cde034c5150c78 (patch) | |
tree | 21c785e01745c5a26b0c775ce327c9d8376e9e30 /src | |
parent | e4358906fdbd0b2df1889dad49c79a9c8cee5ac4 (diff) |
patch 8.2.1166: once mouse move events are enabled getchar() returns themv8.2.1166
Problem: Once mouse move events are enabled getchar() returns them.
Solution: Ignore K_MOUSEMOVE in getchar(). (closes #6424)
Diffstat (limited to 'src')
-rw-r--r-- | src/getchar.c | 4 | ||||
-rw-r--r-- | src/version.c | 2 |
2 files changed, 4 insertions, 2 deletions
diff --git a/src/getchar.c b/src/getchar.c index 2beffa5784..e040748d66 100644 --- a/src/getchar.c +++ b/src/getchar.c @@ -1501,7 +1501,7 @@ openscript( { update_topline_cursor(); // update cursor position and topline normal_cmd(&oa, FALSE); // execute one command - vpeekc(); // check for end of file + (void)vpeekc(); // check for end of file } while (scriptin[oldcurscript] != NULL); @@ -2045,7 +2045,7 @@ f_getchar(typval_T *argvars, typval_T *rettv) // getchar(0) and char avail: return char n = plain_vgetc(); - if (n == K_IGNORE) + if (n == K_IGNORE || n == K_MOUSEMOVE) continue; break; } diff --git a/src/version.c b/src/version.c index 06f3f27caa..9fcf578ffc 100644 --- a/src/version.c +++ b/src/version.c @@ -755,6 +755,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 1166, +/**/ 1165, /**/ 1164, |