From 53251e23cf3f82950c5de1c2208d9f376b5bb5f0 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Thu, 20 Aug 2015 11:18:56 +0200 Subject: Set QAction::NoRole on dock widget view actions. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Prevent the actions from being shuffled around in OS X menus since the default is QAction::TextHeuristicRole. Task-number: QTBUG-47739 Change-Id: Ib68bb7c51eb9278a99d277473f9d4cfcf740431c Reviewed-by: Oswald Buddenhagen Reviewed-by: Morten Johan Sørvig --- src/widgets/widgets/qdockwidget.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/widgets/widgets/qdockwidget.cpp b/src/widgets/widgets/qdockwidget.cpp index 6ea92e4c4d..8b0263fc0c 100644 --- a/src/widgets/widgets/qdockwidget.cpp +++ b/src/widgets/widgets/qdockwidget.cpp @@ -614,6 +614,7 @@ void QDockWidgetPrivate::init() #ifndef QT_NO_ACTION toggleViewAction = new QAction(q); toggleViewAction->setCheckable(true); + toggleViewAction->setMenuRole(QAction::NoRole); fixedWindowTitle = qt_setWindowTitle_helperHelper(q->windowTitle(), q); toggleViewAction->setText(fixedWindowTitle); QObject::connect(toggleViewAction, SIGNAL(triggered(bool)), -- cgit v1.2.3