From 26bade9b9ae120cfc110692ee9c7f69ab029aeaf Mon Sep 17 00:00:00 2001 From: Ryan Stewart Date: Mon, 16 Apr 2012 22:51:48 -0700 Subject: [PATCH 1/2] Fix for issue #657 --- src/command/KeyMap.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/command/KeyMap.js b/src/command/KeyMap.js index c40d52468f6..b006a27e4be 100644 --- a/src/command/KeyMap.js +++ b/src/command/KeyMap.js @@ -24,15 +24,19 @@ define(function (require, exports, module) { } var keyDescriptor = []; - if (hasCtrl) { - keyDescriptor.push("Ctrl"); - } if (hasAlt) { keyDescriptor.push("Alt"); } + if (hasShift) { keyDescriptor.push("Shift"); } + + if (hasCtrl) { + keyDescriptor.push("Ctrl"); + } + + keyDescriptor.push(key); return keyDescriptor.join("-"); From 0ce5205a479528cbf27cc3b1bff165e1ae2aef3e Mon Sep 17 00:00:00 2001 From: Ryan Stewart Date: Tue, 17 Apr 2012 11:23:35 -0700 Subject: [PATCH 2/2] Modified code to be correct order on windows. Thanks @tyvoliter --- src/command/KeyMap.js | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/command/KeyMap.js b/src/command/KeyMap.js index b006a27e4be..5e9acd0ee4c 100644 --- a/src/command/KeyMap.js +++ b/src/command/KeyMap.js @@ -3,7 +3,7 @@ */ /*jslint vars: true, plusplus: true, devel: true, browser: true, nomen: true, indent: 4, maxerr: 50 */ -/*global define: false */ +/*global define: false, brackets: false */ define(function (require, exports, module) { 'use strict'; @@ -33,10 +33,14 @@ define(function (require, exports, module) { } if (hasCtrl) { - keyDescriptor.push("Ctrl"); + // Windows display Ctrl first, Mac displays Command symbol last + if (brackets.platform === "win") { + keyDescriptor.unshift("Ctrl"); + } else { + keyDescriptor.push("Ctrl"); + } } - - + keyDescriptor.push(key); return keyDescriptor.join("-");