mirror of
https://github.com/chylex/IntelliJ-IdeaVim.git
synced 2025-08-15 02:17:05 +02:00
[IDEA-211429] Directly enable insert mode for dialogs
This commit is contained in:
@@ -28,7 +28,6 @@ import com.intellij.openapi.editor.event.*;
|
||||
import com.intellij.openapi.editor.ex.EditorEx;
|
||||
import com.intellij.openapi.project.Project;
|
||||
import com.maddyhome.idea.vim.EventFacade;
|
||||
import com.maddyhome.idea.vim.KeyHandler;
|
||||
import com.maddyhome.idea.vim.VimPlugin;
|
||||
import com.maddyhome.idea.vim.command.CommandState;
|
||||
import com.maddyhome.idea.vim.helper.*;
|
||||
@@ -39,7 +38,6 @@ import org.jdom.Element;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
import javax.swing.*;
|
||||
import java.awt.*;
|
||||
import java.util.List;
|
||||
|
||||
@@ -94,7 +92,7 @@ public class EditorGroup {
|
||||
// Turn on insert mode if editor doesn't have any file
|
||||
if (!EditorData.isFileEditor(editor) && editor.getDocument().isWritable() &&
|
||||
!CommandState.inInsertMode(editor)) {
|
||||
KeyHandler.getInstance().handleKey(editor, KeyStroke.getKeyStroke('i'), new EditorDataContext(editor));
|
||||
VimPlugin.getChange().insertBeforeCursor(editor, new EditorDataContext(editor));
|
||||
}
|
||||
editor.getSettings().setBlockCursor(!CommandState.inInsertMode(editor));
|
||||
editor.getSettings().setAnimatedScrolling(ANIMATED_SCROLLING_VIM_VALUE);
|
||||
|
Reference in New Issue
Block a user