fix: enable mnemonics for menu hotkeys on macOS (#6778)

Reviewed-by: pajlada <rasmus.karlsson+github@pajlada.com>
This commit is contained in:
leafyzito
2026-01-27 19:19:12 -01:00
committed by GitHub
parent a632c89448
commit b69ab9315f
2 changed files with 8 additions and 0 deletions
+7
View File
@@ -42,6 +42,10 @@
# include "corefoundation/CFBundle.h"
#endif
// Forward declaration (Qt doesn't declare this in headers)
// NOLINTNEXTLINE(readability-identifier-naming)
extern void qt_set_sequence_auto_mnemonic(bool b);
namespace chatterino {
namespace {
void installCustomPalette()
@@ -101,6 +105,9 @@ void initQt()
// On the Mac/Cocoa platform this attribute is enabled by default
// We override it to ensure shortcuts show in context menus on that platform
QApplication::setAttribute(Qt::AA_DontShowShortcutsInContextMenus, false);
// Enable mnemonics (menu hotkeys) on macOS - they are disabled by default
qt_set_sequence_auto_mnemonic(true);
#endif
installCustomPalette();