diff --git a/lib/ace/keyboard/emacs.js b/lib/ace/keyboard/emacs.js index b1543894..272071d1 100644 --- a/lib/ace/keyboard/emacs.js +++ b/lib/ace/keyboard/emacs.js @@ -444,10 +444,6 @@ exports.handler.addCommands({ // in multi select mode, ea selection is handled individually if (args && args.count) { - function moveToMark() { - var mark = editor.popEmacsMark(); - mark && editor.moveCursorToPosition(mark); - } if (editor.inMultiSelectMode) editor.forEachSelection({exec: moveToMark}); else moveToMark(); return; @@ -473,6 +469,14 @@ exports.handler.addCommands({ editor.setEmacsMark(rangePositions[rangePositions.length-1]); return; } + + // -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- + + function moveToMark() { + var mark = editor.popEmacsMark(); + mark && editor.moveCursorToPosition(mark); + } + }, readOnly: true, handlesCount: true,