mirror of
https://github.com/VSCodeVim/Vim.git
synced 2024-11-09 05:21:49 +03:00
fixes #652
This commit is contained in:
parent
c20a6632c4
commit
d7321e1f65
@ -1208,7 +1208,6 @@ class CommandInsertInSearchMode extends BaseCommand {
|
||||
searchState.searchString = searchState.searchString.slice(0, -1);
|
||||
} else if (key === "\n") {
|
||||
vimState.currentMode = ModeName.Normal;
|
||||
vimState.cursorPosition = searchState.getNextSearchMatchPosition(vimState.cursorPosition).pos;
|
||||
|
||||
// Repeat the previous search if no new string is entered
|
||||
if (searchState.searchString === "") {
|
||||
@ -1220,6 +1219,9 @@ class CommandInsertInSearchMode extends BaseCommand {
|
||||
// Store this search
|
||||
vimState.searchStatePrevious = searchState;
|
||||
|
||||
// Move cursor to next match
|
||||
vimState.cursorPosition = searchState.getNextSearchMatchPosition(vimState.cursorPosition).pos;
|
||||
|
||||
return vimState;
|
||||
} else if (key === "<Esc>") {
|
||||
vimState.currentMode = ModeName.Normal;
|
||||
|
Loading…
Reference in New Issue
Block a user