QMdiSubWindow: Hide "system" menu icons on macOS
Not only they should not appear (icons in menus is a special thing on macOS), they don't match the look on the window frame buttons. So, it's better to hide them completely. Change-Id: I8814ed3e128480abff4f53fdd40a0bb13f1796ef Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>bb10
parent
8633e1a7b4
commit
347cfa00a2
|
|
@ -1986,6 +1986,13 @@ void QMdiSubWindowPrivate::updateActions()
|
|||
for (int i = 0; i < NumWindowStateActions; ++i)
|
||||
setVisible(WindowStateAction(i), false);
|
||||
|
||||
#ifdef Q_OS_MACOS
|
||||
if (q_func()->style()->inherits("QMacStyle"))
|
||||
for (int i = 0; i < NumWindowStateActions; ++i)
|
||||
if (QAction *action = actions[i])
|
||||
action->setIconVisibleInMenu(false);
|
||||
#endif
|
||||
|
||||
if (windowFlags & Qt::FramelessWindowHint)
|
||||
return;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue