diff options
Diffstat (limited to 'platform/platform-api/src/com/intellij/openapi/editor/actionSystem/TypedAction.java')
-rw-r--r-- | platform/platform-api/src/com/intellij/openapi/editor/actionSystem/TypedAction.java | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/platform/platform-api/src/com/intellij/openapi/editor/actionSystem/TypedAction.java b/platform/platform-api/src/com/intellij/openapi/editor/actionSystem/TypedAction.java index 28bc0f0510ed..1e49937e7765 100644 --- a/platform/platform-api/src/com/intellij/openapi/editor/actionSystem/TypedAction.java +++ b/platform/platform-api/src/com/intellij/openapi/editor/actionSystem/TypedAction.java @@ -64,18 +64,7 @@ public class TypedAction { try { final String str = String.valueOf(charTyped); CommandProcessor.getInstance().setCurrentCommandName(EditorBundle.message("typing.in.editor.command.name")); - - if (editor.getCaretModel().getAllCarets().size() == 1) { // temporary fix for completion - going forward we shouldn't use this check - EditorModificationUtil.typeInStringAtCaretHonorBlockSelection(editor, str, true); - } - else { - editor.getCaretModel().runForEachCaret(new CaretAction() { - @Override - public void perform(Caret caret) { - EditorModificationUtil.typeInStringAtCaretHonorBlockSelection(editor, str, true); - } - }); - } + EditorModificationUtil.typeInStringAtCaretHonorMultipleCarets(editor, str, true); } catch (ReadOnlyFragmentModificationException e) { EditorActionManager.getInstance().getReadonlyFragmentModificationHandler(doc).handle(e); |