diff options
author | Gareth Stockwell <ext-gareth.stockwell@nokia.com> | 2011-02-09 15:00:26 (GMT) |
---|---|---|
committer | Gareth Stockwell <ext-gareth.stockwell@nokia.com> | 2011-02-09 15:01:54 (GMT) |
commit | bf47aa67e286f31db5a8b84060f278f7fea217b2 (patch) | |
tree | 94a91fed57d19ecaf42a894a4718a3c05aec3564 | |
parent | b52bf57e46520fb65d3d4c43bdb9c3d972690cb8 (diff) | |
download | Qt-bf47aa67e286f31db5a8b84060f278f7fea217b2.zip Qt-bf47aa67e286f31db5a8b84060f278f7fea217b2.tar.gz Qt-bf47aa67e286f31db5a8b84060f278f7fea217b2.tar.bz2 |
Fix build failure
Task-number: QTBUG-17288
Reviewed-by: trustme
-rw-r--r-- | src/gui/image/qpixmap_s60.cpp | 9 | ||||
-rw-r--r-- | src/gui/image/qpixmap_s60_p.h | 3 |
2 files changed, 6 insertions, 6 deletions
diff --git a/src/gui/image/qpixmap_s60.cpp b/src/gui/image/qpixmap_s60.cpp index a7aeb84..ca5f133 100644 --- a/src/gui/image/qpixmap_s60.cpp +++ b/src/gui/image/qpixmap_s60.cpp @@ -1012,17 +1012,18 @@ void QS60PixmapData::fromNativeType(void* pixmap, NativeType nativeType) } } -void QS60PixmapData::convertToDisplayMode(TDisplayMode mode) +void QS60PixmapData::convertToDisplayMode(int mode) { - if (!cfbsBitmap || cfbsBitmap->DisplayMode() == mode) + const TDisplayMode displayMode = static_cast<TDisplayMode>(mode); + if (!cfbsBitmap || cfbsBitmap->DisplayMode() == displayMode) return; - if (image.depth() != TDisplayModeUtils::NumDisplayModeBitsPerPixel(mode)) { + if (image.depth() != TDisplayModeUtils::NumDisplayModeBitsPerPixel(displayMode)) { qWarning("Cannot convert display mode due to depth mismatch"); return; } const TSize size = cfbsBitmap->SizeInPixels(); - QScopedPointer<CFbsBitmap> newBitmap(createSymbianCFbsBitmap(size, mode)); + QScopedPointer<CFbsBitmap> newBitmap(createSymbianCFbsBitmap(size, displayMode)); const uchar *sptr = const_cast<const QImage &>(image).bits(); symbianBitmapDataAccess->beginDataAccess(newBitmap.data()); diff --git a/src/gui/image/qpixmap_s60_p.h b/src/gui/image/qpixmap_s60_p.h index c1d7941..c440bbc 100644 --- a/src/gui/image/qpixmap_s60_p.h +++ b/src/gui/image/qpixmap_s60_p.h @@ -54,7 +54,6 @@ // #include <QtGui/private/qpixmap_raster_p.h> -#include <displaymode.h> QT_BEGIN_NAMESPACE @@ -108,7 +107,7 @@ public: void* toNativeType(NativeType type); void fromNativeType(void* pixmap, NativeType type); - void convertToDisplayMode(TDisplayMode mode); + void convertToDisplayMode(int mode); private: void release(); |