diff options
author | Alan Alpert <alan.alpert@nokia.com> | 2012-07-11 17:32:16 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-07-17 07:26:15 +0200 |
commit | feb996e3ab44e68082c97102556ea396f5df3f44 (patch) | |
tree | 7613a8a4eaf5a8e0fb2801e9d0d9d1869524c348 /src/quick/scenegraph | |
parent | 68bbdacd2d5a6fa02f085a996411fb2b71875174 (diff) |
QQuickCanvas renames
QQuickCanvas is now called QQuickWindow
QQuickCanvas::rootItem is now QQuickWindow::contentItem
QQuickItem::canvas is now QQuickItem::window
QQuickItem::ItemChangeData::canvas is also renamed window
QQuickCanvas::grabFrameBuffer is now QQuickWindow::grabWindow
The functions related to the color property have dropped the clear from
their names.
The first three changes have interim compatibility measures in place to
ease the transition.
Change-Id: Id34e29546a22a74a7ae2ad90ee3a8def6fc541d2
Reviewed-by: Martin Jones <martin.jones@nokia.com>
Diffstat (limited to 'src/quick/scenegraph')
-rw-r--r-- | src/quick/scenegraph/qsgcontext.cpp | 4 | ||||
-rw-r--r-- | src/quick/scenegraph/qsgcontext_p.h | 4 | ||||
-rw-r--r-- | src/quick/scenegraph/qsgshareddistancefieldglyphcache.cpp | 10 | ||||
-rw-r--r-- | src/quick/scenegraph/util/qsgtexture.cpp | 2 |
4 files changed, 10 insertions, 10 deletions
diff --git a/src/quick/scenegraph/qsgcontext.cpp b/src/quick/scenegraph/qsgcontext.cpp index 47cc6670f2..ed6a75d669 100644 --- a/src/quick/scenegraph/qsgcontext.cpp +++ b/src/quick/scenegraph/qsgcontext.cpp @@ -190,7 +190,7 @@ void QSGContext::invalidate() } -QSGTexture *QSGContext::textureForFactory(QQuickTextureFactory *factory, QQuickCanvas *canvas) +QSGTexture *QSGContext::textureForFactory(QQuickTextureFactory *factory, QQuickWindow *window) { Q_D(QSGContext); if (!factory) @@ -202,7 +202,7 @@ QSGTexture *QSGContext::textureForFactory(QQuickTextureFactory *factory, QQuickC if (QQuickDefaultTextureFactory *dtf = qobject_cast<QQuickDefaultTextureFactory *>(factory)) texture = createTexture(dtf->image()); else - texture = factory->createTexture(canvas); + texture = factory->createTexture(window); d->textures.insert(factory, texture); connect(factory, SIGNAL(destroyed(QObject *)), this, SLOT(textureFactoryDestroyed(QObject *)), Qt::DirectConnection); } diff --git a/src/quick/scenegraph/qsgcontext_p.h b/src/quick/scenegraph/qsgcontext_p.h index a2495a8029..99fbdd2300 100644 --- a/src/quick/scenegraph/qsgcontext_p.h +++ b/src/quick/scenegraph/qsgcontext_p.h @@ -65,7 +65,7 @@ class QSGImageNode; class QSGGlyphNode; class QSGRenderer; class QSGDistanceFieldGlyphCache; -class QQuickCanvas; +class QQuickWindow; class QSGTexture; class QSGMaterial; class QSGMaterialShader; @@ -111,7 +111,7 @@ public: virtual QSurfaceFormat defaultSurfaceFormat() const; - QSGTexture *textureForFactory(QQuickTextureFactory *factory, QQuickCanvas *canvas); + QSGTexture *textureForFactory(QQuickTextureFactory *factory, QQuickWindow *window); static QSGContext *createDefaultContext(); diff --git a/src/quick/scenegraph/qsgshareddistancefieldglyphcache.cpp b/src/quick/scenegraph/qsgshareddistancefieldglyphcache.cpp index e6bd529d52..dcbff84264 100644 --- a/src/quick/scenegraph/qsgshareddistancefieldglyphcache.cpp +++ b/src/quick/scenegraph/qsgshareddistancefieldglyphcache.cpp @@ -54,7 +54,7 @@ #include <qpa/qplatformsharedgraphicscache.h> -#include <QtQuick/qquickcanvas.h> +#include <QtQuick/qquickwindow.h> // #define QSGSHAREDDISTANCEFIELDGLYPHCACHE_DEBUG @@ -228,12 +228,12 @@ QSGSharedDistanceFieldGlyphCache::QSGSharedDistanceFieldGlyphCache(const QByteAr this, SLOT(reportItemsInvalidated(QByteArray,QVector<quint32>)), Qt::DirectConnection); - QQuickCanvas *canvas = static_cast<QQuickCanvas *>(c->surface()); - Q_ASSERT(canvas != 0); + QQuickWindow *window = static_cast<QQuickWindow *>(c->surface()); + Q_ASSERT(window != 0); - connect(canvas, SIGNAL(beforeSynchronizing()), this, SLOT(sceneGraphUpdateStarted()), + connect(window, SIGNAL(beforeSynchronizing()), this, SLOT(sceneGraphUpdateStarted()), Qt::DirectConnection); - connect(canvas, SIGNAL(beforeRendering()), this, SLOT(sceneGraphUpdateDone()), + connect(window, SIGNAL(beforeRendering()), this, SLOT(sceneGraphUpdateDone()), Qt::DirectConnection); } diff --git a/src/quick/scenegraph/util/qsgtexture.cpp b/src/quick/scenegraph/util/qsgtexture.cpp index c3f15cc568..facf077cd1 100644 --- a/src/quick/scenegraph/util/qsgtexture.cpp +++ b/src/quick/scenegraph/util/qsgtexture.cpp @@ -191,7 +191,7 @@ static void qt_debug_remove_texture(QSGTexture* texture) masks. The scene graph backend provides a default implementation of normal color textures. As the implementation of these may be hardware specific, they are are constructed via the factory - function QQuickCanvas::createTextureFromImage(). + function QQuickWindow::createTextureFromImage(). The texture is a wrapper around an OpenGL texture, which texture id is given by textureId() and which size in pixels is given by |