diff --git a/src/plugins/platforms/cocoa/qcocoamenu.mm b/src/plugins/platforms/cocoa/qcocoamenu.mm index 9e466deb9a..e64386cc5a 100644 --- a/src/plugins/platforms/cocoa/qcocoamenu.mm +++ b/src/plugins/platforms/cocoa/qcocoamenu.mm @@ -133,7 +133,8 @@ void QCocoaMenu::insertMenuItem(QPlatformMenuItem *menuItem, QPlatformMenuItem * void QCocoaMenu::insertNative(QCocoaMenuItem *item, QCocoaMenuItem *beforeItem) { [item->nsItem() setTarget:m_delegate]; - [item->nsItem() setAction:@selector(itemFired:)]; + if (!item->menu()) + [item->nsItem() setAction:@selector(itemFired:)]; if (item->isMerged()) return;