Created
December 14, 2009 22:28
-
-
Save boucher/256498 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| diff --git a/AppKit/CPMenuItem/CPMenuItem.j b/AppKit/CPMenuItem/CPMenuItem.j | |
| index 0c482a9..bdc9745 100644 | |
| --- a/AppKit/CPMenuItem/CPMenuItem.j | |
| +++ b/AppKit/CPMenuItem/CPMenuItem.j | |
| @@ -592,14 +592,31 @@ CPControlKeyMask | |
| var string = _keyEquivalent.toUpperCase(); | |
| - if (_keyEquivalentModifierMask & CPCommandKeyMask) | |
| - string = "⌘" + string; | |
| + if (CPBrowserIsOperatingSystem(CPMacOperatingSystem)) | |
| + { | |
| + if (_keyEquivalentModifierMask & CPControlKeyMask) | |
| + string = "⌥" + string; | |
| + | |
| + if (_keyEquivalentModifierMask & CPCommandKeyMask) | |
| + string = "⌘" + string; | |
| + | |
| + if (_keyEquivalentModifierMask & CPShiftKeyMask) | |
| + string = "⇧" + string; | |
| + | |
| + if (_keyEquivalentModifierMask & CPControlKeyMask) | |
| + string = "^" + string; | |
| + } | |
| + else | |
| + { | |
| + if (_keyEquivalentModifierMask & CPShiftKeyMask) | |
| + string = "Shift-" + string; | |
| - if (_keyEquivalentModifierMask & CPShiftKeyMask) | |
| - string = "⇧" + string; | |
| + if (_keyEquivalentModifierMask & CPAlternateKeyMask) | |
| + string = "Alt-" + string; | |
| - if (_keyEquivalentModifierMask & CPControlKeyMask) | |
| - string = "^" + string; | |
| + if (_keyEquivalentModifierMask & CPControlKeyMask) | |
| + string = "Ctrl-" + string; | |
| + } | |
| return string; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment