Use the right attribute when checking if shortcuts are shown

Change-Id: I784965dda64551e6093af817881aa6472d2cc226
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
bb10
Andy Shaw 2018-01-30 00:32:36 +01:00
parent 3061730c2a
commit 83b0abf928
1 changed files with 1 additions and 1 deletions

View File

@ -1332,7 +1332,7 @@ bool QAction::isShortcutVisibleInContextMenu() const
{
Q_D(const QAction);
if (d->shortcutVisibleInContextMenu == -1) {
if (QApplication::instance()->testAttribute(Qt::AA_DontShowIconsInMenus))
if (QApplication::instance()->testAttribute(Qt::AA_DontShowShortcutsInContextMenus))
return false;
return qApp->styleHints()->showShortcutsInContextMenus();
}