diff --git a/src/mode/modeHandler.ts b/src/mode/modeHandler.ts index 5adaa22d499..d9fb0d65bf8 100644 --- a/src/mode/modeHandler.ts +++ b/src/mode/modeHandler.ts @@ -486,7 +486,7 @@ export class ModeHandler implements vscode.Disposable { var newPosition = new Position(selection.active.line, selection.active.character); if (newPosition.character >= newPosition.getLineEnd().character) { - newPosition = new Position(newPosition.line, Math.max(newPosition.getLineEnd().character, 0)); + newPosition = new Position(newPosition.line, Math.max(newPosition.getLineEnd().character - 1, 0)); } this._vimState.cursorPosition = newPosition; @@ -524,7 +524,7 @@ export class ModeHandler implements vscode.Disposable { } } - await this.updateView(this._vimState, false); + await this.updateView(this._vimState, true); } }