From a0547b7b9d887db173b1463b79e64a77f4fd8c32 Mon Sep 17 00:00:00 2001 From: mtaran-google Date: Fri, 1 Jul 2016 16:01:35 -0700 Subject: [PATCH] [sublime] Make goSubwordLeft/Right shortcuts match Sublime on OSX --- keymap/sublime.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/keymap/sublime.js b/keymap/sublime.js index ed6b847428..db9f54de16 100644 --- a/keymap/sublime.js +++ b/keymap/sublime.js @@ -52,8 +52,10 @@ }); } - cmds[map["Alt-Left"] = "goSubwordLeft"] = function(cm) { moveSubword(cm, -1); }; - cmds[map["Alt-Right"] = "goSubwordRight"] = function(cm) { moveSubword(cm, 1); }; + var goSubwordCombo = mac ? "Ctrl-" : "Alt-"; + + cmds[map[goSubwordCombo + "Left"] = "goSubwordLeft"] = function(cm) { moveSubword(cm, -1); }; + cmds[map[goSubwordCombo + "Right"] = "goSubwordRight"] = function(cm) { moveSubword(cm, 1); }; if (mac) map["Cmd-Left"] = "goLineStartSmart";