diff options
author | Jake Petroules <jake.petroules@qt.io> | 2017-04-10 10:32:14 -0700 |
---|---|---|
committer | Jake Petroules <jake.petroules@qt.io> | 2017-04-13 21:39:09 +0000 |
commit | 401d9b527823ffc8691e8a624ee3d40495622359 (patch) | |
tree | ae10e7d53bc810f9a3402cd9f34f480d0d0d3e67 /tests/auto/widgets/styles/qstyle/tst_qstyle.cpp | |
parent | 4b0d6704d9e44b19c14958c031186ea17370755d (diff) |
Remove the Windows XP style from public accessibility
Later, the Windows XP style will be removed entirely by means of
being merged with the Windows Vista style (which inherits from the
XP style).
There was actually no reason for these styles being separate
classes in the first place, because both result in the same
appearance for controls on the running version of Windows.
Therefore, the windowsxp style merely appears as a "broken"
version of the windowsvista style, with only minor differences
based on the additional metrics that the vista style provides.
The windowsxp style does NOT, and never did, allow users to get
a Windows XP style appearance on Windows 7 and above (which is
currently Qt's minimum supported platform). Therefore, now that
Qt no longer supports Windows XP, the windowsxp style is unusable.
[ChangeLog][QtWidgets] The windowsxp style is no longer available
as a separate style, because it did not (and cannot) actually
provide an XP-style appearance on currently supported Qt platforms.
Change-Id: I513d9bce3f247f97cfb28dfee88fe888469e0a6f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
Diffstat (limited to 'tests/auto/widgets/styles/qstyle/tst_qstyle.cpp')
-rw-r--r-- | tests/auto/widgets/styles/qstyle/tst_qstyle.cpp | 23 |
1 files changed, 1 insertions, 22 deletions
diff --git a/tests/auto/widgets/styles/qstyle/tst_qstyle.cpp b/tests/auto/widgets/styles/qstyle/tst_qstyle.cpp index 5925b764dd..a6b1761d4c 100644 --- a/tests/auto/widgets/styles/qstyle/tst_qstyle.cpp +++ b/tests/auto/widgets/styles/qstyle/tst_qstyle.cpp @@ -86,9 +86,6 @@ private slots: void testFusionStyle(); #endif void testWindowsStyle(); -#if defined(Q_OS_WIN) && !defined(QT_NO_STYLE_WINDOWSXP) - void testWindowsXPStyle(); -#endif #if defined(Q_OS_WIN) && !defined(QT_NO_STYLE_WINDOWSVISTA) void testWindowsVistaStyle(); #endif @@ -147,12 +144,7 @@ void tst_QStyle::testStyleFactory() QVERIFY(keys.contains("Windows")); #endif #ifdef Q_OS_WIN - if (QSysInfo::WindowsVersion >= QSysInfo::WV_XP && - (QSysInfo::WindowsVersion & QSysInfo::WV_NT_based)) - QVERIFY(keys.contains("WindowsXP")); - if (QSysInfo::WindowsVersion >= QSysInfo::WV_VISTA && - (QSysInfo::WindowsVersion & QSysInfo::WV_NT_based)) - QVERIFY(keys.contains("WindowsVista")); + QVERIFY(keys.contains("WindowsVista")); #endif foreach (QString styleName , keys) { @@ -340,17 +332,6 @@ void tst_QStyle::testWindowsStyle() delete wstyle; } -#if defined(Q_OS_WIN) && !defined(QT_NO_STYLE_WINDOWSXP) -// WindowsXP style -void tst_QStyle::testWindowsXPStyle() -{ - QStyle *xpstyle = QStyleFactory::create("WindowsXP"); - QVERIFY(testAllFunctions(xpstyle)); - lineUpLayoutTest(xpstyle); - delete xpstyle; -} -#endif - void writeImage(const QString &fileName, QImage image) { QImageWriter imageWriter(fileName); @@ -373,8 +354,6 @@ void tst_QStyle::testWindowsVistaStyle() if (QSysInfo::WindowsVersion == QSysInfo::WV_VISTA) testPainting(vistastyle, "vista"); - else if (QSysInfo::WindowsVersion == QSysInfo::WV_XP) - testPainting(vistastyle, "xp"); delete vistastyle; } #endif |