ejbills / DockDoor

Window peeking for macOS
https://dockdoor.net
GNU General Public License v3.0
1.2k stars 32 forks source link

quit menu item keyEquivalent #103

Open ShlomoCode opened 3 months ago

ShlomoCode commented 3 months ago

How is it possible to activate the keyboard shortcut? I can't do it, neither when the DockDoor settings are open nor when it's closed. If this is indeed not possible, the indication of the shortcut keys must be displayed, to avoid confusion.

ejbills commented 3 months ago

It works for me when I don't have CMD set for the window switcher. I'm not sure how we can disable that built-in quit shortcut. I think we should just remove it, if possible.

ShlomoCode commented 3 months ago

It's a macOS shortcut that should be valid in every application, I don't think it's worth removing. We just need to find a way not to display it in the menu bar but only when not in the settings window. It is defined here

ShlomoCode commented 3 months ago

Apple Human Interface Guidelines:

In general, don’t repurpose standard keyboard shortcuts for custom actions. People can get confused when the shortcuts they know work differently in your app or game. Only consider redefining a standard shortcut if its action doesn’t make sense in your experience. For example, if your app doesn’t support text editing, it doesn’t need a text-styling command like Italic, so you might repurpose Command–I for an action that has more relevance, like Get Info.

People expect each of the following standard keyboard shortcuts to perform the action listed in the table below.

...

Command-Q Quit the app.

ShlomoCode commented 3 months ago

Ok, I see that when focused on the window, the keyboard shortcut doesn't work. So you just need to remove the keyEquivalent from the menu bar item, and instead add a keyEquivalent for the settings window.

ShlomoCode commented 3 months ago

Maybe we would also like to add a "quit" button in the corner of the settings window?

ShlomoCode commented 3 months ago

https://github.com/sindresorhus/Settings/issues/40