diff options
| author | Tomáš Znamenáček | 2015-01-08 10:50:08 +0100 | 
|---|---|---|
| committer | Tomáš Znamenáček | 2015-01-08 10:50:08 +0100 | 
| commit | ea69d5939511f61a7082ba1e8ff46d247862a3fa (patch) | |
| tree | a8107774609d5f4263f7b79749d93e6c6ff2642d /Framework/MASShortcutValidator.m | |
| parent | d2a371c92e7570042f52cced866c383ebe6e4268 (diff) | |
| download | MASShortcut-ea69d5939511f61a7082ba1e8ff46d247862a3fa.tar.bz2 | |
Ignore disabled system shortcuts.
This was implemented before in 0633545a, but lost during the rebase.
Diffstat (limited to 'Framework/MASShortcutValidator.m')
| -rw-r--r-- | Framework/MASShortcutValidator.m | 4 | 
1 files changed, 3 insertions, 1 deletions
| diff --git a/Framework/MASShortcutValidator.m b/Framework/MASShortcutValidator.m index 1db3ed9..47dd700 100644 --- a/Framework/MASShortcutValidator.m +++ b/Framework/MASShortcutValidator.m @@ -88,9 +88,11 @@              CFDictionaryRef hotKeyInfo = CFArrayGetValueAtIndex(globalHotKeys, i);              CFNumberRef code = CFDictionaryGetValue(hotKeyInfo, kHISymbolicHotKeyCode);              CFNumberRef flags = CFDictionaryGetValue(hotKeyInfo, kHISymbolicHotKeyModifiers); +            CFNumberRef enabled = CFDictionaryGetValue(hotKeyInfo, kHISymbolicHotKeyEnabled);              if (([(__bridge NSNumber *)code unsignedIntegerValue] == [shortcut keyCode]) && -                ([(__bridge NSNumber *)flags unsignedIntegerValue] == [shortcut carbonFlags])) { +                ([(__bridge NSNumber *)flags unsignedIntegerValue] == [shortcut carbonFlags]) && +                ([(__bridge NSNumber *)enabled boolValue])) {                  if (explanation) {                      *explanation = NSLocalizedString(@"This combination cannot be used because it is already used by a system-wide " | 
