diff options
author | Sona Kurazyan <sona.kurazyan@qt.io> | 2019-07-10 17:04:42 +0200 |
---|---|---|
committer | Sona Kurazyan <sona.kurazyan@qt.io> | 2019-07-13 10:43:15 +0200 |
commit | 2f33e030b8c80b4665cc2c120df7833469c05145 (patch) | |
tree | c82580c8ef761ddd5e22f695dc5934753429436d /tests/benchmarks/gui/image | |
parent | e89b2f72c7147e46dcf606c3dcc507e2ae2841ce (diff) |
Remove usages of deprecated APIs of qtbase/gui
- Replaced the usages of deprecated APIs by corresponding
alternatives in the library code and documentation.
- Modified the tests to make them build when deprecated APIs disabled:
* Made the the parts of the tests testing the deprecated APIs to
be compiled conditionally, only when the corresponding methods are
enabled.
* If the test-case tests only the deprecated API, but not the
corresponding replacement, added tests for the replacement.
Change-Id: Ic38245015377fc0c8127eb5458c184ffd4b450f1
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'tests/benchmarks/gui/image')
-rw-r--r-- | tests/benchmarks/gui/image/qpixmapcache/tst_qpixmapcache.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/benchmarks/gui/image/qpixmapcache/tst_qpixmapcache.cpp b/tests/benchmarks/gui/image/qpixmapcache/tst_qpixmapcache.cpp index d4be85b5ad..2ded426cdd 100644 --- a/tests/benchmarks/gui/image/qpixmapcache/tst_qpixmapcache.cpp +++ b/tests/benchmarks/gui/image/qpixmapcache/tst_qpixmapcache.cpp @@ -106,7 +106,7 @@ void tst_QPixmapCache::find() if (cacheType) { QBENCHMARK { for (int i = 0 ; i <= 10000 ; i++) - QPixmapCache::find(QString::asprintf("my-key-%d", i), p); + QPixmapCache::find(QString::asprintf("my-key-%d", i), &p); } } else { QBENCHMARK { @@ -155,7 +155,7 @@ void tst_QPixmapCache::styleUseCaseComplexKey() QPixmapCache::insert(QString::asprintf("%s-%d-%d-%d-%d-%d-%d", QString("my-progressbar-%1").arg(i).toLatin1().constData(), 5, 3, 0, 358, 100, 200), p); for (int i = 0 ; i <= 10000 ; i++) - QPixmapCache::find(QString::asprintf("%s-%d-%d-%d-%d-%d-%d", QString("my-progressbar-%1").arg(i).toLatin1().constData(), 5, 3, 0, 358, 100, 200), p); + QPixmapCache::find(QString::asprintf("%s-%d-%d-%d-%d-%d-%d", QString("my-progressbar-%1").arg(i).toLatin1().constData(), 5, 3, 0, 358, 100, 200), &p); } } else { QHash<styleStruct, QPixmapCache::Key> hash; |