diff options
Diffstat (limited to 'src/plugins')
-rw-r--r-- | src/plugins/codecs/jp/qeucjpcodec.cpp | 1 | ||||
-rw-r--r-- | src/plugins/gfxdrivers/directfb/qdirectfbpaintengine.cpp | 91 | ||||
-rw-r--r-- | src/plugins/gfxdrivers/directfb/qdirectfbwindowsurface.cpp | 3 | ||||
-rw-r--r-- | src/plugins/imageformats/jpeg/jpeg.pro | 4 | ||||
-rw-r--r-- | src/plugins/imageformats/mng/mng.pro | 4 | ||||
-rw-r--r-- | src/plugins/qpluginbase.pri | 1 |
6 files changed, 52 insertions, 52 deletions
diff --git a/src/plugins/codecs/jp/qeucjpcodec.cpp b/src/plugins/codecs/jp/qeucjpcodec.cpp index 76353a3..cdc6619 100644 --- a/src/plugins/codecs/jp/qeucjpcodec.cpp +++ b/src/plugins/codecs/jp/qeucjpcodec.cpp @@ -79,7 +79,6 @@ QT_BEGIN_NAMESPACE #ifndef QT_NO_TEXTCODEC -static const uchar Esc = 0x1b; static const uchar Ss2 = 0x8e; // Single Shift 2 static const uchar Ss3 = 0x8f; // Single Shift 3 diff --git a/src/plugins/gfxdrivers/directfb/qdirectfbpaintengine.cpp b/src/plugins/gfxdrivers/directfb/qdirectfbpaintengine.cpp index 3185664..ade8554 100644 --- a/src/plugins/gfxdrivers/directfb/qdirectfbpaintengine.cpp +++ b/src/plugins/gfxdrivers/directfb/qdirectfbpaintengine.cpp @@ -81,7 +81,7 @@ template <> inline const bool* ptr<bool>(const bool &) { return 0; } template <typename device, typename T1, typename T2, typename T3> static void rasterFallbackWarn(const char *msg, const char *func, const device *dev, int scale, bool matrixRotShear, bool simplePen, - bool dfbHandledClip, + bool dfbHandledClip, bool unsupportedCompositionMode, const char *nameOne, const T1 &one, const char *nameTwo, const T2 &two, const char *nameThree, const T3 &three) @@ -98,7 +98,8 @@ static void rasterFallbackWarn(const char *msg, const char *func, const device * dbg << "scale" << scale << "matrixRotShear" << matrixRotShear << "simplePen" << simplePen - << "dfbHandledClip" << dfbHandledClip; + << "dfbHandledClip" << dfbHandledClip + << "unsupportedCompositionMode" << unsupportedCompositionMode; const T1 *t1 = ptr(one); const T2 *t2 = ptr(two); @@ -124,6 +125,7 @@ static void rasterFallbackWarn(const char *msg, const char *func, const device * __FUNCTION__, state()->painter->device(), \ d_func()->scale, d_func()->matrixRotShear, \ d_func()->simplePen, d_func()->dfbCanHandleClip(), \ + d_func()->unsupportedCompositionMode, \ #one, one, #two, two, #three, three); \ if (op & (QT_DIRECTFB_DISABLE_RASTERFALLBACKS)) \ return; @@ -138,6 +140,7 @@ static void rasterFallbackWarn(const char *msg, const char *func, const device * __FUNCTION__, state()->painter->device(), \ d_func()->scale, d_func()->matrixRotShear, \ d_func()->simplePen, d_func()->dfbCanHandleClip(), \ + d_func()->unsupportedCompositionMode, \ #one, one, #two, two, #three, three); #else #define RASTERFALLBACK(op, one, two, three) @@ -244,9 +247,6 @@ public: inline void updateClip(); void systemStateChanged(); - void begin(QPaintDevice *device); - void end(); - static IDirectFBSurface *getSurface(const QImage &img, bool *release); #ifdef QT_DIRECTFB_IMAGECACHE @@ -299,7 +299,34 @@ QDirectFBPaintEngine::~QDirectFBPaintEngine() bool QDirectFBPaintEngine::begin(QPaintDevice *device) { Q_D(QDirectFBPaintEngine); - d->begin(device); + d->lastLockedHeight = -1; + if (device->devType() == QInternal::CustomRaster) { + d->dfbDevice = static_cast<QDirectFBPaintDevice*>(device); + } else if (device->devType() == QInternal::Pixmap) { + QPixmapData *data = static_cast<QPixmap*>(device)->pixmapData(); + Q_ASSERT(data->classId() == QPixmapData::DirectFBClass); + QDirectFBPixmapData *dfbPixmapData = static_cast<QDirectFBPixmapData*>(data); + d->dfbDevice = static_cast<QDirectFBPaintDevice*>(dfbPixmapData); + } + + if (d->dfbDevice) + d->surface = d->dfbDevice->directFBSurface(); + + if (!d->surface) { + qFatal("QDirectFBPaintEngine used on an invalid device: 0x%x", + device->devType()); + } + d->lockedMemory = 0; + + d->surface->GetSize(d->surface, &d->fbWidth, &d->fbHeight); + + d->setTransform(QTransform()); + d->antialiased = false; + d->setOpacity(255); + d->setCompositionMode(state()->compositionMode()); + d->dirtyClip = true; + d->setPen(state()->pen); + const bool status = QRasterPaintEngine::begin(device); // XXX: QRasterPaintEngine::begin() resets the capabilities @@ -311,7 +338,13 @@ bool QDirectFBPaintEngine::begin(QPaintDevice *device) bool QDirectFBPaintEngine::end() { Q_D(QDirectFBPaintEngine); - d->end(); + d->unlock(); + d->dfbDevice = 0; +#if (Q_DIRECTFB_VERSION >= 0x010000) + d->surface->ReleaseSource(d->surface); +#endif + d->surface->SetClip(d->surface, NULL); + d->surface = 0; return QRasterPaintEngine::end(); } @@ -873,48 +906,6 @@ void QDirectFBPaintEnginePrivate::setTransform(const QTransform &m) } } -void QDirectFBPaintEnginePrivate::begin(QPaintDevice *device) -{ - lastLockedHeight = -1; - if (device->devType() == QInternal::CustomRaster) - dfbDevice = static_cast<QDirectFBPaintDevice*>(device); - else if (device->devType() == QInternal::Pixmap) { - QPixmapData *data = static_cast<QPixmap*>(device)->pixmapData(); - Q_ASSERT(data->classId() == QPixmapData::DirectFBClass); - QDirectFBPixmapData* dfbPixmapData = static_cast<QDirectFBPixmapData*>(data); - dfbDevice = static_cast<QDirectFBPaintDevice*>(dfbPixmapData); - } - - if (dfbDevice) - surface = dfbDevice->directFBSurface(); - - if (!surface) { - qFatal("QDirectFBPaintEngine used on an invalid device: 0x%x", - device->devType()); - } - lockedMemory = 0; - - surface->GetSize(surface, &fbWidth, &fbHeight); - - setTransform(QTransform()); - antialiased = false; - setOpacity(255); - setCompositionMode(q->state()->compositionMode()); - dirtyClip = true; - setPen(q->state()->pen); -} - -void QDirectFBPaintEnginePrivate::end() -{ - lockedMemory = 0; - dfbDevice = 0; -#if (Q_DIRECTFB_VERSION >= 0x010000) - surface->ReleaseSource(surface); -#endif - surface->SetClip(surface, NULL); - surface = 0; -} - void QDirectFBPaintEnginePrivate::setPen(const QPen &p) { pen = p; @@ -1071,6 +1062,8 @@ void QDirectFBPaintEnginePrivate::blit(const QRectF &dest, IDirectFBSurface *s, { const QRect sr = src.toRect(); const QRect dr = transform.mapRect(dest).toRect(); + if (dr.isEmpty()) + return; const DFBRectangle sRect = { sr.x(), sr.y(), sr.width(), sr.height() }; DFBResult result; diff --git a/src/plugins/gfxdrivers/directfb/qdirectfbwindowsurface.cpp b/src/plugins/gfxdrivers/directfb/qdirectfbwindowsurface.cpp index 5deca3c..86ee62c 100644 --- a/src/plugins/gfxdrivers/directfb/qdirectfbwindowsurface.cpp +++ b/src/plugins/gfxdrivers/directfb/qdirectfbwindowsurface.cpp @@ -252,7 +252,6 @@ void QDirectFBWindowSurface::setPermanentState(const QByteArray &state) static inline void scrollSurface(IDirectFBSurface *surface, const QRect &r, int dx, int dy) { - surface->SetBlittingFlags(surface, DSBLIT_NOFX); const DFBRectangle rect = { r.x(), r.y(), r.width(), r.height() }; surface->Blit(surface, surface, &rect, r.x() + dx, r.y() + dy); } @@ -365,6 +364,7 @@ void QDirectFBWindowSurface::flush(QWidget *widget, const QRegion ®ion, if (winOpacity != opacity) dfbWindow->SetOpacity(dfbWindow, winOpacity); } +#endif if (!(flipFlags & DSFLIP_BLIT)) { dfbSurface->Flip(dfbSurface, 0, flipFlags); } else { @@ -386,7 +386,6 @@ void QDirectFBWindowSurface::flush(QWidget *widget, const QRegion ®ion, dfbSurface->Flip(dfbSurface, &dfbReg, flipFlags); } } -#endif #ifdef QT_DIRECTFB_TIMING enum { Secs = 3 }; ++frames; diff --git a/src/plugins/imageformats/jpeg/jpeg.pro b/src/plugins/imageformats/jpeg/jpeg.pro index e2e1a66..f8893a0 100644 --- a/src/plugins/imageformats/jpeg/jpeg.pro +++ b/src/plugins/imageformats/jpeg/jpeg.pro @@ -13,6 +13,10 @@ wince*: { contains(CE_ARCH,x86):CONFIG += exceptions_off } +symbian: { + QMAKE_CXXFLAGS.CW += -W nounusedarg +} + contains(QT_CONFIG, system-jpeg) { unix:LIBS += -ljpeg win32:LIBS += libjpeg.lib diff --git a/src/plugins/imageformats/mng/mng.pro b/src/plugins/imageformats/mng/mng.pro index 35cb47a..e391ebc 100644 --- a/src/plugins/imageformats/mng/mng.pro +++ b/src/plugins/imageformats/mng/mng.pro @@ -7,6 +7,10 @@ HEADERS += qmnghandler.h SOURCES += main.cpp \ qmnghandler.cpp +symbian: { + QMAKE_CXXFLAGS.CW += -W nounused +} + contains(QT_CONFIG, system-mng) { unix:LIBS += -lmng win32:LIBS += libmng.lib diff --git a/src/plugins/qpluginbase.pri b/src/plugins/qpluginbase.pri index 6d3e266..b14f839 100644 --- a/src/plugins/qpluginbase.pri +++ b/src/plugins/qpluginbase.pri @@ -17,4 +17,5 @@ wince*:LIBS += $$QMAKE_LIBS_GUI symbian: { TARGET.EPOCALLOWDLLDATA=1 TARGET.CAPABILITY = All -Tcb + load(armcc_warnings) } |