comparison src/message.c @ 20571:5995db0fe84a v8.2.0839

patch 8.2.0839: dropping modifier when putting a character back in typeahead Commit: https://github.com/vim/vim/commit/b42c0d54279b1fdb79652db0c84171e213458809 Author: Bram Moolenaar <Bram@vim.org> Date: Fri May 29 22:41:41 2020 +0200 patch 8.2.0839: dropping modifier when putting a character back in typeahead Problem: Dropping modifier when putting a character back in typeahead. Solution: Add modifier to ins_char_typebuf(). (closes https://github.com/vim/vim/issues/6158)
author Bram Moolenaar <Bram@vim.org>
date Fri, 29 May 2020 22:45:05 +0200
parents 7196cd9d8397
children c4bce986c31a
comparison
equal deleted inserted replaced
20570:c08ee6345092 20571:5995db0fe84a
1256 (void)jump_to_mouse(MOUSE_SETPOS, NULL, 0); 1256 (void)jump_to_mouse(MOUSE_SETPOS, NULL, 0);
1257 else if (vim_strchr((char_u *)"\r\n ", c) == NULL && c != Ctrl_C) 1257 else if (vim_strchr((char_u *)"\r\n ", c) == NULL && c != Ctrl_C)
1258 { 1258 {
1259 // Put the character back in the typeahead buffer. Don't use the 1259 // Put the character back in the typeahead buffer. Don't use the
1260 // stuff buffer, because lmaps wouldn't work. 1260 // stuff buffer, because lmaps wouldn't work.
1261 ins_char_typebuf(c); 1261 ins_char_typebuf(vgetc_char, vgetc_mod_mask);
1262 do_redraw = TRUE; // need a redraw even though there is 1262 do_redraw = TRUE; // need a redraw even though there is
1263 // typeahead 1263 // typeahead
1264 } 1264 }
1265 } 1265 }
1266 redir_off = FALSE; 1266 redir_off = FALSE;
3710 if (c < 0) // special keys are ignored here 3710 if (c < 0) // special keys are ignored here
3711 continue; 3711 continue;
3712 if (c == ':' && ex_cmd) 3712 if (c == ':' && ex_cmd)
3713 { 3713 {
3714 retval = dfltbutton; 3714 retval = dfltbutton;
3715 ins_char_typebuf(':'); 3715 ins_char_typebuf(':', 0);
3716 break; 3716 break;
3717 } 3717 }
3718 3718
3719 // Make the character lowercase, as chars in "hotkeys" are. 3719 // Make the character lowercase, as chars in "hotkeys" are.
3720 c = MB_TOLOWER(c); 3720 c = MB_TOLOWER(c);