summaryrefslogtreecommitdiffstats
path: root/src/gui/image
diff options
context:
space:
mode:
authorJørgen Lind <jorgen.lind@nokia.com>2010-07-21 07:58:25 (GMT)
committerJørgen Lind <jorgen.lind@nokia.com>2010-07-22 10:05:41 (GMT)
commit96f1f3d575a12967657bb534ee5accc04d52984e (patch)
treed2ff8af3d06d0f93afca04b39713ab4daf3709df /src/gui/image
parent77d17d054b8baff411613206a099af36f8e0bc43 (diff)
downloadQt-96f1f3d575a12967657bb534ee5accc04d52984e.zip
Qt-96f1f3d575a12967657bb534ee5accc04d52984e.tar.gz
Qt-96f1f3d575a12967657bb534ee5accc04d52984e.tar.bz2
Removed createBlittable factory function from PlatformIntegration
and moved it onto QBlittablePixmap making the class abstract. The creator function was seen as to spesialised to be part of the PlatformIntegration class, and belonged to the QBlittablePixmap class anyway since that was the PixmapData type you would need to return to use the blitter api. Also removed the cross platform examples as they are more confusing than anything else. For usage of QBlittable look in the directfb platform integration plugin.
Diffstat (limited to 'src/gui/image')
-rw-r--r--src/gui/image/qpixmap_blitter.cpp10
-rw-r--r--src/gui/image/qpixmap_blitter_p.h3
2 files changed, 5 insertions, 8 deletions
diff --git a/src/gui/image/qpixmap_blitter.cpp b/src/gui/image/qpixmap_blitter.cpp
index d91a269..9a7ebe2 100644
--- a/src/gui/image/qpixmap_blitter.cpp
+++ b/src/gui/image/qpixmap_blitter.cpp
@@ -14,8 +14,8 @@ QT_BEGIN_NAMESPACE
static int global_ser_no = 0;
-QBlittablePixmapData::QBlittablePixmapData(QPixmapData::PixelType type)
- : QPixmapData(type,BlitterClass), m_engine(0), m_blittable(0)
+QBlittablePixmapData::QBlittablePixmapData()
+ : QPixmapData(QPixmapData::PixmapType,BlitterClass), m_engine(0), m_blittable(0)
#ifdef QT_BLITTER_RASTEROVERLAY
,m_rasterOverlay(0), m_unmergedCopy(0)
#endif //QT_BLITTER_RASTEROVERLAY
@@ -37,11 +37,7 @@ QBlittable *QBlittablePixmapData::blittable() const
{
if (!m_blittable) {
QBlittablePixmapData *that = const_cast<QBlittablePixmapData *>(this);
-#ifdef Q_WS_QPA //####jl: graphics system nor platformintegration should have createBlittable
- that->m_blittable = QApplicationPrivate::platformIntegration()->createBlittable(QSize(w,h));
-#else
- that->m_blittable = QApplicationPrivate::graphicsSystem()->createBlittable(QSize(w,h));
-#endif
+ that->m_blittable = this->createBlittable(QSize(w,h));
}
return m_blittable;
diff --git a/src/gui/image/qpixmap_blitter_p.h b/src/gui/image/qpixmap_blitter_p.h
index b9f7630..e404199 100644
--- a/src/gui/image/qpixmap_blitter_p.h
+++ b/src/gui/image/qpixmap_blitter_p.h
@@ -11,9 +11,10 @@ class Q_GUI_EXPORT QBlittablePixmapData : public QPixmapData
{
// Q_DECLARE_PRIVATE(QBlittablePixmapData);
public:
- QBlittablePixmapData(QPixmapData::PixelType type);
+ QBlittablePixmapData();
~QBlittablePixmapData();
+ virtual QBlittable *createBlittable(const QSize &size) const = 0;
QBlittable *blittable() const;
void setBlittable(QBlittable *blittable);