Set "About Qt Designer plugins..." menu entry role to NoRole

This fixes a problem on Mac, where the default menu role is TextHeuristic,
and menu item syncing would reassing this entry as "About Qt Creator". Also
ProxyAction would not forward the menu role.

Task-number: QTBUG-30679
Change-Id: If5ad5fb3a34131c080543bf8160e9ab5140c8585
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This commit is contained in:
Gabriel de Dietrich
2013-04-18 10:42:12 +02:00
parent 1a35103344
commit fae2052549
2 changed files with 5 additions and 2 deletions

View File

@@ -120,8 +120,10 @@ void ProxyAction::update(QAction *action, bool initialize)
return;
disconnectAction();
disconnect(this, SIGNAL(changed()), this, SLOT(updateToolTipWithKeySequence()));
if (initialize)
if (initialize) {
setSeparator(action->isSeparator());
setMenuRole(action->menuRole());
}
if (hasAttribute(UpdateIcon) || initialize) {
setIcon(action->icon());
setIconText(action->iconText());

View File

@@ -561,7 +561,8 @@ void FormEditorW::setupActions()
addToolAction(actionFormSettings, m_contexts, Core::Id("FormEditor.FormSettings"), mformtools);
mformtools->addSeparator(m_contexts);
m_actionAboutPlugins = new QAction(tr("About Qt Designer plugins...."), this);
m_actionAboutPlugins = new QAction(tr("About Qt Designer plugins..."), this);
m_actionAboutPlugins->setMenuRole(QAction::NoRole);
addToolAction(m_actionAboutPlugins, m_contexts,
Core::Id("FormEditor.AboutPlugins"), mformtools);
connect(m_actionAboutPlugins, SIGNAL(triggered()), m_fwm,