summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2011-03-21 12:33:30 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2011-03-21 12:33:30 (GMT)
commit12689cc05936d675c8a7065cf39b8334b83f95bb (patch)
treec77f27c34fa09adafa879a5b183b056a7adbb3be /src/gui
parentdeefcaaa5bfaf22ee31ae9da2965ab627b0c43b5 (diff)
parent8621d989b80bd384826569e6f6fec25fe3327c94 (diff)
downloadQt-12689cc05936d675c8a7065cf39b8334b83f95bb.zip
Qt-12689cc05936d675c8a7065cf39b8334b83f95bb.tar.gz
Qt-12689cc05936d675c8a7065cf39b8334b83f95bb.tar.bz2
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-s60-public into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/qt-s60-public: Change the pooled QGLPixmapData to be backed by QVolatileImage. Started changes-4.7.4 file Changed s60 style not to rely on QPixmapData::toNativeType(). Add missing bitmap locking to QVGPixmapData::fromNativeType. Prepare fromSymbianCFbsBitmap autotest for 16 bpp format.
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/styles/qs60style_s60.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/gui/styles/qs60style_s60.cpp b/src/gui/styles/qs60style_s60.cpp
index 1ff195d..e46c826 100644
--- a/src/gui/styles/qs60style_s60.cpp
+++ b/src/gui/styles/qs60style_s60.cpp
@@ -639,13 +639,14 @@ QPixmap QS60StyleModeSpecifics::fromFbsBitmap(CFbsBitmap *icon, CFbsBitmap *mask
QPixmap pixmap;
QScopedPointer<QPixmapData> pd(QPixmapData::create(0, 0, QPixmapData::PixmapType));
- bool nativeMaskSupported = (pd->toNativeType(QPixmapData::VolatileImage) != 0);
- if (mask && nativeMaskSupported) {
- // Efficient path, less copying and conversion.
+ if (mask) {
+ // Try the efficient path with less copying and conversion.
QVolatileImage img(icon, mask);
pd->fromNativeType(&img, QPixmapData::VolatileImage);
- pixmap = QPixmap(pd.take());
- } else {
+ if (!pd->isNull())
+ pixmap = QPixmap(pd.take());
+ }
+ if (pixmap.isNull()) {
// Potentially more expensive path.
pd->fromNativeType(icon, QPixmapData::FbsBitmap);
pixmap = QPixmap(pd.take());