fixes #0001485: 'About FreeCAD' disappears on Mac OS X
This commit is contained in:
parent
ca6d372025
commit
72314b1b57
|
@ -191,6 +191,11 @@ QString Action::whatsThis() const
|
|||
return _action->whatsThis();
|
||||
}
|
||||
|
||||
void Action::setMenuRole(QAction::MenuRole menuRole)
|
||||
{
|
||||
_action->setMenuRole(menuRole);
|
||||
}
|
||||
|
||||
// --------------------------------------------------------------------
|
||||
|
||||
/**
|
||||
|
|
|
@ -68,6 +68,7 @@ public:
|
|||
QString toolTip() const;
|
||||
void setWhatsThis (const QString &);
|
||||
QString whatsThis() const;
|
||||
void setMenuRole(QAction::MenuRole menuRole);
|
||||
|
||||
public Q_SLOTS:
|
||||
virtual void onActivated ();
|
||||
|
|
|
@ -208,7 +208,9 @@ Action * StdCmdAbout::createAction(void)
|
|||
pcAction->setWhatsThis(QLatin1String(sWhatsThis));
|
||||
pcAction->setIcon(QApplication::windowIcon());
|
||||
pcAction->setShortcut(QString::fromAscii(sAccel));
|
||||
|
||||
//Prevent Qt from using AboutRole -- fixes issue #0001485
|
||||
pcAction->setMenuRole(QAction::ApplicationSpecificRole);
|
||||
|
||||
return pcAction;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user