summaryrefslogtreecommitdiff
path: root/tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp
diff options
context:
space:
mode:
authorJ-P Nurmi <jpnurmi@gmail.com>2012-11-17 00:52:26 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-11-23 15:18:15 +0100
commit27aa41cbba6c0bd76148fde63863cfbba0ec2456 (patch)
treed49ef13e32d9294c30c7e2017beee3ff71264c0c /tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp
parentd25572cc7b1dc414d2c0b1b575334f8152346a31 (diff)
downloadqtbase-27aa41cbba6c0bd76148fde63863cfbba0ec2456.tar.gz
Made QMacStyle internal
We will take this opportynity to remove various QStyle specializations from the public API in Qt5. This gives us much more freedom, for example changing the inheritance hierarchy, pluginizing etc. without worrying about BC. => Use QStyleFactory and/or QProxyStyle instead of creating an instance or inheriting QMacStyle directly. Change-Id: I44a2f5ee3fe08ecc837b593a2a2737eb90e8c267 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
Diffstat (limited to 'tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp')
-rw-r--r--tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp b/tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp
index e4c76cd237..7e68db0e8c 100644
--- a/tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp
+++ b/tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp
@@ -57,10 +57,6 @@
#include <QRadioButton>
#include <private/qlayoutengine_p.h>
-#ifdef Q_OS_MAC
-# include <QtWidgets/QMacStyle>
-#endif
-
class tst_QLayout : public QObject
{
Q_OBJECT
@@ -276,7 +272,7 @@ public:
void tst_QLayout::layoutItemRect()
{
#ifdef Q_OS_MAC
- if (qobject_cast<QMacStyle*>(QApplication::style())) {
+ if (QApplication::style()->inherits("QMacStyle")) {
QWidget *window = new QWidget;
QRadioButton *radio = new QRadioButton(window);
QWidgetItem item(radio);