From fd29b71a833ef0f491a67129ee8d172784fe8e06 Mon Sep 17 00:00:00 2001 From: nightwing Date: Thu, 20 Oct 2016 08:19:20 +0000 Subject: [PATCH 1/2] update mac keybindings --- .../ace/lib/ace/commands/default_commands.js | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/node_modules/ace/lib/ace/commands/default_commands.js b/node_modules/ace/lib/ace/commands/default_commands.js index de14df85..372b95a3 100644 --- a/node_modules/ace/lib/ace/commands/default_commands.js +++ b/node_modules/ace/lib/ace/commands/default_commands.js @@ -55,7 +55,7 @@ exports.commands = [{ readOnly: true }, { name: "goToNextError", - bindKey: bindKey("Alt-E", "Ctrl-E"), + bindKey: bindKey("Alt-E", "F4"), exec: function(editor) { config.loadModule("ace/ext/error_marker", function(module) { module.showErrorMarker(editor, 1); @@ -65,7 +65,7 @@ exports.commands = [{ readOnly: true }, { name: "goToPreviousError", - bindKey: bindKey("Alt-Shift-E", "Ctrl-Shift-E"), + bindKey: bindKey("Alt-Shift-E", "Shift-F4"), exec: function(editor) { config.loadModule("ace/ext/error_marker", function(module) { module.showErrorMarker(editor, -1); @@ -190,7 +190,7 @@ exports.commands = [{ readOnly: true }, { name: "selecttostart", - bindKey: bindKey("Ctrl-Shift-Home", "Command-Shift-Up"), + bindKey: bindKey("Ctrl-Shift-Home", "Command-Shift-Home|Command-Shift-Up"), exec: function(editor) { editor.getSelection().selectFileStart(); }, multiSelectAction: "forEach", readOnly: true, @@ -206,7 +206,7 @@ exports.commands = [{ aceCommandGroup: "fileJump" }, { name: "selectup", - bindKey: bindKey("Shift-Up", "Shift-Up"), + bindKey: bindKey("Shift-Up", "Shift-Up|Ctrl-Shift-P"), exec: function(editor) { editor.getSelection().selectUp(); }, multiSelectAction: "forEach", scrollIntoView: "cursor", @@ -220,7 +220,7 @@ exports.commands = [{ readOnly: true }, { name: "selecttoend", - bindKey: bindKey("Ctrl-Shift-End", "Command-Shift-Down"), + bindKey: bindKey("Ctrl-Shift-End", "Command-Shift-End|Command-Shift-Down"), exec: function(editor) { editor.getSelection().selectFileEnd(); }, multiSelectAction: "forEach", readOnly: true, @@ -236,7 +236,7 @@ exports.commands = [{ aceCommandGroup: "fileJump" }, { name: "selectdown", - bindKey: bindKey("Shift-Down", "Shift-Down"), + bindKey: bindKey("Shift-Down", "Shift-Down|Ctrl-Shift-N"), exec: function(editor) { editor.getSelection().selectDown(); }, multiSelectAction: "forEach", scrollIntoView: "cursor", @@ -264,7 +264,7 @@ exports.commands = [{ readOnly: true }, { name: "selecttolinestart", - bindKey: bindKey("Alt-Shift-Left", "Command-Shift-Left"), + bindKey: bindKey("Alt-Shift-Left", "Command-Shift-Left|Ctrl-Shift-A"), exec: function(editor) { editor.getSelection().selectLineStart(); }, multiSelectAction: "forEach", scrollIntoView: "cursor", @@ -278,7 +278,7 @@ exports.commands = [{ readOnly: true }, { name: "selectleft", - bindKey: bindKey("Shift-Left", "Shift-Left"), + bindKey: bindKey("Shift-Left", "Shift-Left|Ctrl-Shift-B"), exec: function(editor) { editor.getSelection().selectLeft(); }, multiSelectAction: "forEach", scrollIntoView: "cursor", @@ -306,7 +306,7 @@ exports.commands = [{ readOnly: true }, { name: "selecttolineend", - bindKey: bindKey("Alt-Shift-Right", "Command-Shift-Right"), + bindKey: bindKey("Alt-Shift-Right", "Command-Shift-Right|Shift-End|Ctrl-Shift-E"), exec: function(editor) { editor.getSelection().selectLineEnd(); }, multiSelectAction: "forEach", scrollIntoView: "cursor", From 5dbe2f2aafc47c0de7ba8d745bc9e55188dcbf86 Mon Sep 17 00:00:00 2001 From: nightwing Date: Fri, 21 Oct 2016 12:13:36 +0000 Subject: [PATCH 2/2] add command-left/right support to terminal --- plugins/c9.ide.terminal/aceterm/input.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/plugins/c9.ide.terminal/aceterm/input.js b/plugins/c9.ide.terminal/aceterm/input.js index 424afcbd..bf781417 100644 --- a/plugins/c9.ide.terminal/aceterm/input.js +++ b/plugins/c9.ide.terminal/aceterm/input.js @@ -77,6 +77,12 @@ define(function(require, exports, module) { }, { bindKey: {win: "Ctrl-z", mac: "Cmd-z"}, name: "\u0018\u0015" // "ctrl-x ctrl-u" + }, { + bindKey: {win: null, mac: "Cmd-Left"}, + name: "\x1b[1~" // "ctrl-x ctrl-u" + }, { + bindKey: {win: null, mac: "Cmd-Right"}, + name: "\x1b[4~" // "ctrl-x ctrl-u" }]; specialKeys.addCommands(aliases);