Allow FL_COMMAND+'+' as macOS system menu shortcuts - cont'd

This commit is contained in:
ManoloFLTK 2024-02-26 17:48:18 +01:00
parent 0818d4ec5b
commit 3f794d3abe

View File

@ -437,7 +437,7 @@ static int process_sys_menu_shortcuts(int event)
// is the last event the shortcut of an item of the fl_sys_menu_bar menu ?
const Fl_Menu_Item *item = fl_sys_menu_bar->menu()->test_shortcut();
if (!item) return 0;
if (item->visible()) // have the system menu process the shortcut, highlighting the corresponding menu
if (item->visible() && item->shortcut() != FL_COMMAND+'+' ) // have the system menu process the shortcut, highlighting the corresponding menu
[[NSApp mainMenu] performKeyEquivalent:[NSApp currentEvent]];
else // have FLTK process the shortcut associated to an invisible Fl_Menu_Item
fl_sys_menu_bar->picked(item);