Created
June 6, 2013 10:10
-
-
Save plateaukao/5720546 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.maddyhome.idea.vim.key.KeyParser | |
import com.maddyhome.idea.vim.key.Shortcut | |
import com.maddyhome.idea.vim.command.Command | |
import javax.swing.KeyStroke | |
import java.awt.event.KeyEvent | |
// gc, gf, gs, ga でそれぞれのGotoコマンド実行 | |
parser.registerAction(KeyParser.MAPPING_NORMAL, "GotoClass", Command.Type.OTHER_READONLY, new Shortcut("gc")) | |
parser.registerAction(KeyParser.MAPPING_NORMAL, "GotoFile", Command.Type.OTHER_READONLY, new Shortcut("gf")) | |
parser.registerAction(KeyParser.MAPPING_NORMAL, "GotoSymbol", Command.Type.OTHER_READONLY, new Shortcut("gs")) | |
parser.registerAction(KeyParser.MAPPING_NORMAL, "GotoAction", Command.Type.OTHER_READONLY, new Shortcut("ga")) | |
parser.registerAction(KeyParser.MAPPING_NORMAL, "ShowUsages", Command.Type.OTHER_READONLY, new Shortcut("su")) | |
parser.registerAction(KeyParser.MAPPING_NORMAL, "EditorTabPopupMenu", Command.Type.OTHER_READONLY, new Shortcut("gt")) | |
parser.registerAction(KeyParser.MAPPING_NORMAL, "Run", Command.Type.OTHER_READONLY, new Shortcut("gr")) | |
parser.registerAction(KeyParser.MAPPING_NORMAL, "Debug", Command.Type.OTHER_READONLY, new Shortcut("gd")) | |
parser.registerAction(KeyParser.MAPPING_NORMAL, "NextTab", Command.Type.OTHER_READONLY, new Shortcut("bn")) | |
parser.registerAction(KeyParser.MAPPING_NORMAL, "PreviousTab", Command.Type.OTHER_READONLY, new Shortcut("bp")) | |
// Ctrl+] で定義に移動。Ctrl+T で戻る | |
parser.registerAction(KeyParser.MAPPING_NORMAL, "GotoDeclaration", Command.Type.OTHER_READONLY, Command.FLAG_MOT_EXCLUSIVE, | |
new Shortcut(KeyStroke.getKeyStroke(KeyEvent.VK_CLOSE_BRACKET, KeyEvent.CTRL_MASK))) | |
parser.registerAction(KeyParser.MAPPING_NORMAL, "Back", Command.Type.OTHER_READONLY, Command.FLAG_MOT_EXCLUSIVE, | |
new Shortcut(KeyStroke.getKeyStroke(KeyEvent.VK_T, KeyEvent.CTRL_MASK))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment