cocoabits / MASShortcut

Modern framework for managing global keyboard shortcuts compatible with Mac App Store. More details:
http://blog.shpakovski.com/2012/07/global-keyboard-shortcuts-in-cocoa.html
BSD 2-Clause "Simplified" License
1.52k stars 220 forks source link

Shortcuts not working when NSMenu is active? #117

Open kainjow opened 6 years ago

kainjow commented 6 years ago

We're seeing an issue where a registered shortcut does not get called until after a popup button's menu is dismissed.

This sounds like the same or very similar issue: https://github.com/shortcutrecorder/shortcutrecorder/issues/45

Any known issues or workarounds regarding shortcuts and menus?

gee1k commented 4 years ago

If you have menu items with the same function in your menu, you can bind the same shortcut keys to the menu items. And bind or unbind global shortcuts when the menu is opened or closed.

image image image

gee1k commented 4 years ago

final effect:

2019-12-25 10-58-24 2019-12-25 10_59_33