# HG changeset patch # User Bram Moolenaar # Date 1650659402 -7200 # Node ID 9a2fb96475eddb2fde4c5796df2254f3a0aaba9f # Parent 0e4c2e79baacbc7d7d95f1ea1686516033dab479 patch 8.2.4806: a mapping using does not start Select mode Commit: https://github.com/vim/vim/commit/53ef5731480d8b5aa74137a09b3b164b436ed76b Author: Bram Moolenaar Date: Fri Apr 22 21:20:26 2022 +0100 patch 8.2.4806: a mapping using does not start Select mode Problem: A mapping using does not start Select mode. Solution: When checking for starting select mode with the mouse also do this when there is typeahead. (closes #10249) diff --git a/src/normal.c b/src/normal.c --- a/src/normal.c +++ b/src/normal.c @@ -5527,12 +5527,13 @@ start_selection(void) /* * Start Select mode, if "c" is in 'selectmode' and not in a mapping or menu. + * When "c" is 'o' (checking for "mouse") then also when mapped. */ void may_start_select(int c) { - VIsual_select = (stuff_empty() && typebuf_typed() - && (vim_strchr(p_slm, c) != NULL)); + VIsual_select = (c == 'o' || (stuff_empty() && typebuf_typed())) + && vim_strchr(p_slm, c) != NULL; } /* diff --git a/src/version.c b/src/version.c --- a/src/version.c +++ b/src/version.c @@ -747,6 +747,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 4806, +/**/ 4805, /**/ 4804,