From: Gunnar Sletta Date: Mon, 14 Nov 2011 14:11:45 +0000 (+0100) Subject: Fixed assert during QML shutdown X-Git-Url: http://git.silmor.de/gitweb/?a=commitdiff_plain;h=885d3cfd658d2003cea5cdc8b7c347748ce030dd;p=konrad%2Fqtdeclarative.git Fixed assert during QML shutdown Change-Id: I680af9ccb417d3162277b5740a129ecd77feee7f Reviewed-by: Samuel Rødal --- diff --git a/src/declarative/items/qquickcanvas.cpp b/src/declarative/items/qquickcanvas.cpp index dfdaaed..d5003e9 100644 --- a/src/declarative/items/qquickcanvas.cpp +++ b/src/declarative/items/qquickcanvas.cpp @@ -864,6 +864,12 @@ QQuickCanvas::~QQuickCanvas() { Q_D(QQuickCanvas); + /* The threaded renderer will clean up the nodes which will fire + sceneGraphChanged events through back to the canvas. This signal + is connected to maybeUpdate which should only be called from GUI or during + updatePaintNode(), so disconnect them before starting the shutdown + */ + disconnect(d->context->renderer(), SIGNAL(sceneGraphChanged()), this, SLOT(maybeUpdate())); if (d->thread->isRunning()) { d->thread->stopRendering(); delete d->thread;