summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
authorGabriel de Dietrich <gabriel.dedietrich@digia.com>2013-06-27 20:01:05 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-07-01 18:07:57 +0200
commit971bdc90e99db2d6d93d802d389be027189746d2 (patch)
tree3eedc3a7bb1900e3c7f8225f88bba456e549402b /src/gui
parent93e79d865c127aad0de0a44007253845cb291b4a (diff)
QIcon: Avoid fetching twice the same pixmap
Looks like something went through the reviewer's eyes. This commit amends 6ec9b34cbb5fa6b1214cc6551002f46f732ba72f. Change-Id: I59a05361b1cbdf4e5177821d958766ffe3218f16 Reviewed-by: Jake Petroules <jake.petroules@petroules.com> Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/image/qicon.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/image/qicon.cpp b/src/gui/image/qicon.cpp
index 45eda78397..aef7324171 100644
--- a/src/gui/image/qicon.cpp
+++ b/src/gui/image/qicon.cpp
@@ -181,7 +181,7 @@ void QPixmapIconEngine::paint(QPainter *painter, const QRect &rect, QIcon::Mode
{
QSize pixmapSize = rect.size() * qt_effective_device_pixel_ratio(0);
QPixmap px = pixmap(pixmapSize, mode, state);
- painter->drawPixmap(rect, pixmap(pixmapSize, mode, state));
+ painter->drawPixmap(rect, px);
}
static inline int area(const QSize &s) { return s.width() * s.height(); }