mirror of
https://github.com/chylex/IntelliJ-IdeaVim.git
synced 2025-08-29 20:53:09 +02:00
Fix race condition resetting editor on focus gain
Fixes VIM-3773
This commit is contained in:
@@ -80,7 +80,9 @@ class IJEditorFocusListener : EditorListener {
|
|||||||
if (ijEditor.isDisposed) return@invokeLater
|
if (ijEditor.isDisposed) return@invokeLater
|
||||||
val consoleView: ConsoleViewImpl? = ijEditor.getUserData(ConsoleViewImpl.CONSOLE_VIEW_IN_EDITOR_VIEW)
|
val consoleView: ConsoleViewImpl? = ijEditor.getUserData(ConsoleViewImpl.CONSOLE_VIEW_IN_EDITOR_VIEW)
|
||||||
if (consoleView != null && consoleView.isRunning && !ijEditor.inInsertMode) {
|
if (consoleView != null && consoleView.isRunning && !ijEditor.inInsertMode) {
|
||||||
|
// Switch to Insert mode, but make sure we reset the editor to actually make it apply
|
||||||
switchToInsertMode.run()
|
switchToInsertMode.run()
|
||||||
|
KeyHandler.getInstance().reset(editor)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
KeyHandler.getInstance().reset(editor)
|
KeyHandler.getInstance().reset(editor)
|
||||||
|
Reference in New Issue
Block a user