Search code examples
swiftmacosappkit

How to make Mac application respond to command tilde key shortcut to switch windows


In most Mac applications it is possible to switch between the open windows of an application using the cmd ~ key shortcut. I want this in my app too, but I really don't see how to implement.

Most key shortcuts are implemented by adding a shortcut to one of the menu items. But for this one a menu item is not applicable.


Solution

  • In the Keyboard preferences pane, under the Shortcuts pane, Command-` is a system-level keyboard shortcut in the Keyboard category (labeled "Move focus to next window").