diff options
author | axis <qt-info@nokia.com> | 2009-05-18 12:25:08 (GMT) |
---|---|---|
committer | axis <qt-info@nokia.com> | 2009-05-18 12:25:08 (GMT) |
commit | 6e81bfbaf69864a06240835e0b30cdc47a2668b7 (patch) | |
tree | aff37bf74549836696d420477e57f51969e97091 /src/plugins/iconengines | |
parent | 3e5abb158c1924e555dc4142c4be89adc517b8c1 (diff) | |
parent | 7008bfe80e0466ed2978b39e7e698bbd52fb690f (diff) | |
download | Qt-6e81bfbaf69864a06240835e0b30cdc47a2668b7.zip Qt-6e81bfbaf69864a06240835e0b30cdc47a2668b7.tar.gz Qt-6e81bfbaf69864a06240835e0b30cdc47a2668b7.tar.bz2 |
Merge branch '4.5' of git@scm.dev.nokia.troll.no:qt/qt
Conflicts:
configure.exe
src/corelib/kernel/qcoreapplication.cpp
Configure.exe not rebuilt because the changes are irrelevant for the
S60 port. We'll rebuild it before merging back.
Diffstat (limited to 'src/plugins/iconengines')
-rw-r--r-- | src/plugins/iconengines/svgiconengine/qsvgiconengine.cpp | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/src/plugins/iconengines/svgiconengine/qsvgiconengine.cpp b/src/plugins/iconengines/svgiconengine/qsvgiconengine.cpp index c7249d3..3273513 100644 --- a/src/plugins/iconengines/svgiconengine/qsvgiconengine.cpp +++ b/src/plugins/iconengines/svgiconengine/qsvgiconengine.cpp @@ -122,16 +122,10 @@ QSize QSvgIconEngine::actualSize(const QSize &size, QIcon::Mode mode, return size; } - QSvgRenderer renderer; - d->loadDataForModeAndState(&renderer, mode, state); - if (renderer.isValid()) { - QSize defaultSize = renderer.defaultSize(); - if (!defaultSize.isNull()) - defaultSize.scale(size, Qt::KeepAspectRatio); - return defaultSize; - } else { + QPixmap pm = pixmap(size, mode, state); + if (pm.isNull()) return QSize(); - } + return pm.size(); } void QSvgIconEnginePrivate::loadDataForModeAndState(QSvgRenderer *renderer, QIcon::Mode mode, QIcon::State state) |