diff options
author | Christian Ehrlicher <ch.ehrlicher@gmx.de> | 2019-01-25 21:15:43 +0100 |
---|---|---|
committer | Christian Ehrlicher <ch.ehrlicher@gmx.de> | 2019-02-02 12:49:25 +0000 |
commit | daee9af969a04a2919a948ba1f5d314626925a9a (patch) | |
tree | 19f40c501ea42e4fa4deea7d4e102b863d6c6bab /src/gui/image/qicon.cpp | |
parent | df39627fa33392a71ab79aadaa57e5c5e650e79e (diff) |
QtGui: mark obsolete QPixmapCache::find() functions as deprecated
QPixmapCache::find(QString) and QPixmapCache::find(QString, QPixmap&)
are deprecated since Qt4 times.
Explicit mark them as deprecated so they can be removed with Qt6.
Change-Id: Iaf185f69afe02203559a1c812fbb4a95c9049a1d
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Diffstat (limited to 'src/gui/image/qicon.cpp')
-rw-r--r-- | src/gui/image/qicon.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gui/image/qicon.cpp b/src/gui/image/qicon.cpp index 285cdf790a..c3c4b24678 100644 --- a/src/gui/image/qicon.cpp +++ b/src/gui/image/qicon.cpp @@ -315,9 +315,9 @@ QPixmap QPixmapIconEngine::pixmap(const QSize &size, QIcon::Mode mode, QIcon::St % HexString<uint>(actualSize.height()); if (mode == QIcon::Active) { - if (QPixmapCache::find(key % HexString<uint>(mode), pm)) + if (QPixmapCache::find(key % HexString<uint>(mode), &pm)) return pm; // horray - if (QPixmapCache::find(key % HexString<uint>(QIcon::Normal), pm)) { + if (QPixmapCache::find(key % HexString<uint>(QIcon::Normal), &pm)) { QPixmap active = pm; if (QGuiApplication *guiApp = qobject_cast<QGuiApplication *>(qApp)) active = static_cast<QGuiApplicationPrivate*>(QObjectPrivate::get(guiApp))->applyQIconStyleHelper(QIcon::Active, pm); @@ -326,7 +326,7 @@ QPixmap QPixmapIconEngine::pixmap(const QSize &size, QIcon::Mode mode, QIcon::St } } - if (!QPixmapCache::find(key % HexString<uint>(mode), pm)) { + if (!QPixmapCache::find(key % HexString<uint>(mode), &pm)) { if (pm.size() != actualSize) pm = pm.scaled(actualSize, Qt::IgnoreAspectRatio, Qt::SmoothTransformation); if (pe->mode != mode && mode != QIcon::Normal) { |