aboutsummaryrefslogtreecommitdiffstats
path: root/src/declarative/items/qsgcanvas.cpp
diff options
context:
space:
mode:
authorGunnar Sletta <gunnar.sletta@nokia.com>2011-05-05 11:26:47 +0200
committerGunnar Sletta <gunnar.sletta@nokia.com>2011-05-06 07:27:28 +0200
commit55ff812974dd038a597cd968b66c07b6aeff74b2 (patch)
tree74bd30d0b73bfc011c62aa51ef9f0097ec82603e /src/declarative/items/qsgcanvas.cpp
parent24bb6f90f828c0dbed06a56536a3f33b35d36506 (diff)
Make animation driver pluggable through the QSGContext
Diffstat (limited to 'src/declarative/items/qsgcanvas.cpp')
-rw-r--r--src/declarative/items/qsgcanvas.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/declarative/items/qsgcanvas.cpp b/src/declarative/items/qsgcanvas.cpp
index 1ac14a0dea..f2a5ccb4e7 100644
--- a/src/declarative/items/qsgcanvas.cpp
+++ b/src/declarative/items/qsgcanvas.cpp
@@ -213,7 +213,7 @@ void QSGCanvas::showEvent(QShowEvent *e)
d->contextInThread = true;
doneCurrent();
if (!d->animationDriver) {
- d->animationDriver = new QAnimationDriver(this);
+ d->animationDriver = d->context->createAnimationDriver(this);
connect(d->animationDriver, SIGNAL(started()), this, SLOT(_q_animationStarted()), Qt::DirectConnection);
connect(d->animationDriver, SIGNAL(stopped()), this, SLOT(_q_animationStopped()), Qt::DirectConnection);
}
@@ -227,7 +227,7 @@ void QSGCanvas::showEvent(QShowEvent *e)
if (!d->context || !d->context->isReady()) {
d->initializeSceneGraph();
- d->animationDriver = new QAnimationDriver(this);
+ d->animationDriver = d->context->createAnimationDriver(this);
connect(d->animationDriver, SIGNAL(started()), this, SLOT(update()));
}