comparison src/normal.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 b790d00d5ccb
children 4411c2b96af9
comparison
equal deleted inserted replaced
20570:c08ee6345092 20571:5995db0fe84a
593 // Fake a "c"hange command. When "restart_edit" is set (e.g., because 593 // Fake a "c"hange command. When "restart_edit" is set (e.g., because
594 // 'insertmode' is set) fake a "d"elete command, Insert mode will 594 // 'insertmode' is set) fake a "d"elete command, Insert mode will
595 // restart automatically. 595 // restart automatically.
596 // Insert the typed character in the typeahead buffer, so that it can 596 // Insert the typed character in the typeahead buffer, so that it can
597 // be mapped in Insert mode. Required for ":lmap" to work. 597 // be mapped in Insert mode. Required for ":lmap" to work.
598 ins_char_typebuf(c); 598 ins_char_typebuf(vgetc_char, vgetc_mod_mask);
599 if (restart_edit != 0) 599 if (restart_edit != 0)
600 c = 'd'; 600 c = 'd';
601 else 601 else
602 c = 'c'; 602 c = 'c';
603 msg_nowait = TRUE; // don't delay going to insert mode 603 msg_nowait = TRUE; // don't delay going to insert mode