From bf73aac39f73ffe816c89478b8ec857584f1d290 Mon Sep 17 00:00:00 2001 From: Fawzi Mohamed Date: Wed, 27 Feb 2013 01:07:13 +0100 Subject: [PATCH] coreplugin/mac: set menu role before adding menu improves menu behaviour for qt5 on osx Task-number: QTCREATORBUG-8152 Change-Id: I6ff7703d45ff5e250c7fae9a8c85f8d8ef078e16 Reviewed-by: Eike Ziller --- src/plugins/coreplugin/mainwindow.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/plugins/coreplugin/mainwindow.cpp b/src/plugins/coreplugin/mainwindow.cpp index f71a71fde17..911975ca457 100644 --- a/src/plugins/coreplugin/mainwindow.cpp +++ b/src/plugins/coreplugin/mainwindow.cpp @@ -773,19 +773,19 @@ void MainWindow::registerDefaultActions() else tmpaction = new QAction(icon, tr("About &Qt Creator..."), this); cmd = ActionManager::registerAction(tmpaction, Constants::ABOUT_QTCREATOR, globalContext); - mhelp->addAction(cmd, Constants::G_HELP_ABOUT); - tmpaction->setEnabled(true); if (Utils::HostOsInfo::isMacHost()) cmd->action()->setMenuRole(QAction::ApplicationSpecificRole); + mhelp->addAction(cmd, Constants::G_HELP_ABOUT); + tmpaction->setEnabled(true); connect(tmpaction, SIGNAL(triggered()), this, SLOT(aboutQtCreator())); //About Plugins Action tmpaction = new QAction(tr("About &Plugins..."), this); cmd = ActionManager::registerAction(tmpaction, Constants::ABOUT_PLUGINS, globalContext); - mhelp->addAction(cmd, Constants::G_HELP_ABOUT); - tmpaction->setEnabled(true); if (Utils::HostOsInfo::isMacHost()) cmd->action()->setMenuRole(QAction::ApplicationSpecificRole); + mhelp->addAction(cmd, Constants::G_HELP_ABOUT); + tmpaction->setEnabled(true); connect(tmpaction, SIGNAL(triggered()), this, SLOT(aboutPlugins())); // About Qt Action // tmpaction = new QAction(tr("About &Qt..."), this);