diff options
author | Olivier Goffart <olivier.goffart@nokia.com> | 2011-05-11 11:25:30 (GMT) |
---|---|---|
committer | Olivier Goffart <olivier.goffart@nokia.com> | 2011-05-11 11:25:30 (GMT) |
commit | 6532273e52b772f0dd18194782bd3ed4c94ccb26 (patch) | |
tree | a6a2b0926c7693e2699039d1bb0e2cc811120ed6 /src/gui/image | |
parent | 97447d569999372d43f22dbb1e0fc5193b73615c (diff) | |
parent | 1950c400294ac0006b20e8b411e896fc98e3b2bf (diff) | |
download | Qt-6532273e52b772f0dd18194782bd3ed4c94ccb26.zip Qt-6532273e52b772f0dd18194782bd3ed4c94ccb26.tar.gz Qt-6532273e52b772f0dd18194782bd3ed4c94ccb26.tar.bz2 |
Merge remote-tracking branch 'origin/4.7' into qt-4.8-from-4.7
Conflicts:
src/gui/kernel/qwidget_p.h
src/gui/painting/qgraphicssystem_p.h
src/plugins/plugins.pro
src/s60installs/bwins/QtCoreu.def
src/s60installs/bwins/QtDeclarativeu.def
src/s60installs/bwins/QtGuiu.def
src/s60installs/bwins/QtMultimediau.def
src/s60installs/bwins/QtNetworku.def
src/s60installs/bwins/QtOpenGLu.def
src/s60installs/bwins/QtScriptu.def
src/s60installs/bwins/QtSqlu.def
src/s60installs/bwins/QtTestu.def
src/s60installs/bwins/QtXmlPatternsu.def
src/s60installs/bwins/phononu.def
src/s60installs/eabi/QtGuiu.def
src/s60installs/eabi/QtOpenGLu.def
src/s60installs/eabi/QtTestu.def
Diffstat (limited to 'src/gui/image')
-rw-r--r-- | src/gui/image/qimage.cpp | 2 | ||||
-rw-r--r-- | src/gui/image/qpixmap.cpp | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/src/gui/image/qimage.cpp b/src/gui/image/qimage.cpp index 50b372e..25f6295 100644 --- a/src/gui/image/qimage.cpp +++ b/src/gui/image/qimage.cpp @@ -4449,6 +4449,8 @@ QImage QImage::scaled(const QSize& s, Qt::AspectRatioMode aspectMode, Qt::Transf QSize newSize = size(); newSize.scale(s, aspectMode); + newSize.rwidth() = qMax(newSize.width(), 1); + newSize.rheight() = qMax(newSize.height(), 1); if (newSize == size()) return *this; diff --git a/src/gui/image/qpixmap.cpp b/src/gui/image/qpixmap.cpp index c34f6ac..640864d 100644 --- a/src/gui/image/qpixmap.cpp +++ b/src/gui/image/qpixmap.cpp @@ -1514,6 +1514,8 @@ QPixmap QPixmap::scaled(const QSize& s, Qt::AspectRatioMode aspectMode, Qt::Tran QSize newSize = size(); newSize.scale(s, aspectMode); + newSize.rwidth() = qMax(newSize.width(), 1); + newSize.rheight() = qMax(newSize.height(), 1); if (newSize == size()) return *this; |