diff options
author | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-03-29 08:40:49 +0300 |
---|---|---|
committer | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-03-29 08:43:04 +0300 |
commit | d1548176e227df3840c644a8a9d384b14fc842f8 (patch) | |
tree | 6c103b2280b5783253e4099f7215783972d8a641 /src/macos.m | |
parent | e0b41301a8cfaed746ea823c133e69b15d273c0b (diff) |
macOS: Fixed missing menu shortcuts
The built-in alternate bindings shouldn't affect the menu shortcuts.
Diffstat (limited to 'src/macos.m')
-rw-r--r-- | src/macos.m | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/macos.m b/src/macos.m index 0dcc3ef5..61507b6f 100644 --- a/src/macos.m +++ b/src/macos.m | |||
@@ -497,7 +497,7 @@ void insertMenuItems_MacOS(const char *menuLabel, int atIndex, const iMenuItem * | |||
497 | [myDel setCommand:[NSString stringWithUTF8String:items[i].command] forMenuItem:item]; | 497 | [myDel setCommand:[NSString stringWithUTF8String:items[i].command] forMenuItem:item]; |
498 | /* Bindings may have a different key. */ | 498 | /* Bindings may have a different key. */ |
499 | const iBinding *bind = findCommand_Keys(items[i].command); | 499 | const iBinding *bind = findCommand_Keys(items[i].command); |
500 | if (bind) { | 500 | if (bind && bind->id < builtIn_BindingId) { |
501 | key = bind->key; | 501 | key = bind->key; |
502 | kmods = bind->mods; | 502 | kmods = bind->mods; |
503 | } | 503 | } |
@@ -533,7 +533,7 @@ void handleCommand_MacOS(const char *cmd) { | |||
533 | if (command) { | 533 | if (command) { |
534 | const iBinding *bind = findCommand_Keys( | 534 | const iBinding *bind = findCommand_Keys( |
535 | [command cStringUsingEncoding:NSUTF8StringEncoding]); | 535 | [command cStringUsingEncoding:NSUTF8StringEncoding]); |
536 | if (bind) { | 536 | if (bind && bind->id < builtIn_BindingId) { |
537 | setShortcut_NSMenuItem_(menuItem, bind->key, bind->mods); | 537 | setShortcut_NSMenuItem_(menuItem, bind->key, bind->mods); |
538 | } | 538 | } |
539 | } | 539 | } |