1
0
mirror of https://github.com/chylex/IntelliJ-IdeaVim.git synced 2025-08-02 09:59:07 +02:00

Merge remote-tracking branch 'origin/master'

Conflicts:
	build.properties
This commit is contained in:
Andrey Vlasovskikh 2013-11-15 16:11:53 +04:00
commit c1c076830a
5 changed files with 21 additions and 27 deletions
CHANGES.mdbuild.properties
resources/META-INF
src/com/maddyhome/idea/vim

View File

@ -4,6 +4,16 @@ The Changelog
History of changes in IdeaVim for the IntelliJ platform.
0.31, 2013-11-12
----------------
A bugfix release.
Bug fixes:
* VIM-582 Fixed line comment and reformat commands with no visual selection
0.30, 2013-11-11
----------------

View File

@ -1,4 +1,4 @@
version-id:0.30
version-id:0.31
platform-version:120.0
idea.download.url=http://download.jetbrains.com/idea/ideaIU-12.1.zip
build.number=x

View File

@ -3,6 +3,10 @@
<id>IdeaVIM</id>
<change-notes>
<![CDATA[
<p>0.31:</p>
<ul>
<li>Various bug fixes</li>
</ul>
<p>0.30:</p>
<ul>
<li>Support for a separate <code>.ideavimrc</code> config file</li>
@ -26,13 +30,6 @@
<li>Fixed a long-standing bug with code completion and repeat last change command ('<code>.</code>')</li>
<li>Various bug fixes</li>
</ul>
<p>0.26:</p>
<ul>
<li>Added support for paste in the command mode: from a register using <code>&lt;C-R&gt;</code>, from the clipboard using <code>&lt;S-Insert&gt;</code> or <code>&lt;M-V&gt;</code></li>
<li>Added support for the last change position mark (the dot <code>.</code> mark)</li>
<li>New shortcuts for Go to declaration <code>&lt;C-]&gt;</code> and Navigate back <code>&lt;C-T&gt;</code></li>
<li>Various bug fixes</li>
</ul>
<p>See also the complete <a href="https://github.com/JetBrains/ideavim/blob/master/CHANGES.md">changelog</a>.</p>
]]>
</change-notes>

View File

@ -25,9 +25,8 @@ import com.intellij.openapi.editor.Editor;
import com.maddyhome.idea.vim.KeyHandler;
import com.maddyhome.idea.vim.action.AbstractDelegateEditorAction;
import com.maddyhome.idea.vim.command.Command;
import com.maddyhome.idea.vim.common.TextRange;
import com.maddyhome.idea.vim.handler.AbstractEditorActionHandler;
import com.maddyhome.idea.vim.handler.DelegateActionHandler;
import com.maddyhome.idea.vim.handler.VisualOperatorActionHandler;
import org.jetbrains.annotations.NotNull;
public class VisualOperatorDelegateAction extends AbstractDelegateEditorAction {
@ -40,15 +39,9 @@ public class VisualOperatorDelegateAction extends AbstractDelegateEditorAction {
((Handler)getHandler()).setOrigAction(origAction);
}
private static class Handler extends VisualOperatorActionHandler implements DelegateActionHandler {
protected boolean execute(@NotNull Editor editor, @NotNull DataContext context, @NotNull Command cmd,
@NotNull TextRange range) {
if (logger.isDebugEnabled()) {
logger.debug("execute, cmd=" + cmd + ", range=" + range);
logger.debug("origAction=" + origAction);
}
private static class Handler extends AbstractEditorActionHandler implements DelegateActionHandler {
protected boolean execute(@NotNull Editor editor, @NotNull DataContext context, @NotNull Command cmd) {
KeyHandler.executeAction(origAction, context);
return true;
}

View File

@ -20,8 +20,6 @@ package com.maddyhome.idea.vim.helper;
import com.intellij.openapi.actionSystem.DataContext;
import com.intellij.openapi.actionSystem.PlatformDataKeys;
import com.intellij.openapi.command.undo.UndoManager;
import com.intellij.openapi.editor.Editor;
import com.intellij.openapi.fileEditor.FileEditor;
import com.intellij.openapi.project.Project;
import org.jetbrains.annotations.NotNull;
@ -30,16 +28,13 @@ import org.jetbrains.annotations.NotNull;
* @author oleg
*/
public class UndoRedoHelper {
public static boolean undo(@NotNull final DataContext context) {
final Project project = PlatformDataKeys.PROJECT.getData(context);
final FileEditor fileEditor = PlatformDataKeys.FILE_EDITOR.getData(context);
final UndoManager undoManager = UndoManager.getInstance(project);
final com.intellij.openapi.command.undo.UndoManager undoManager = com.intellij.openapi.command.undo.UndoManager.getInstance(project);
if (fileEditor != null && undoManager.isUndoAvailable(fileEditor)) {
undoManager.undo(fileEditor);
final Editor editor = PlatformDataKeys.EDITOR.getData(context);
if (editor != null) {
editor.getSelectionModel().removeSelection();
}
return true;
}
return false;
@ -48,12 +43,11 @@ public class UndoRedoHelper {
public static boolean redo(@NotNull final DataContext context) {
final Project project = PlatformDataKeys.PROJECT.getData(context);
final FileEditor fileEditor = PlatformDataKeys.FILE_EDITOR.getData(context);
final UndoManager undoManager = UndoManager.getInstance(project);
final com.intellij.openapi.command.undo.UndoManager undoManager = com.intellij.openapi.command.undo.UndoManager.getInstance(project);
if (fileEditor != null && undoManager.isRedoAvailable(fileEditor)) {
undoManager.redo(fileEditor);
return true;
}
return false;
}
}