summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMartin Jones <martin.jones@nokia.com>2009-11-03 06:21:46 (GMT)
committerMartin Jones <martin.jones@nokia.com>2009-11-03 06:21:46 (GMT)
commit88937dc4246006d7a75c2978cd542b11e983c705 (patch)
treefaf2bf15db6302211d3bd9f743f4716d54537c53 /src
parent6f033b6a46ae5cf3dcfed9a2e17182ae58108a00 (diff)
parent57dadc8606eb0c864ef27e550f9a8ae109de5293 (diff)
downloadQt-88937dc4246006d7a75c2978cd542b11e983c705.zip
Qt-88937dc4246006d7a75c2978cd542b11e983c705.tar.gz
Qt-88937dc4246006d7a75c2978cd542b11e983c705.tar.bz2
Merge branch 'kinetic-declarativeui' of git@scm.dev.nokia.troll.no:qt/kinetic into kinetic-declarativeui
Diffstat (limited to 'src')
-rw-r--r--src/declarative/qml/qmlcontext.cpp16
-rw-r--r--src/declarative/qml/qmlcontext_p.h3
2 files changed, 2 insertions, 17 deletions
diff --git a/src/declarative/qml/qmlcontext.cpp b/src/declarative/qml/qmlcontext.cpp
index d37d959..f8e685a 100644
--- a/src/declarative/qml/qmlcontext.cpp
+++ b/src/declarative/qml/qmlcontext.cpp
@@ -88,18 +88,6 @@ void QmlContextPrivate::addScript(const QString &script, QObject *scopeObject,
scripts.append(scope);
}
-void QmlContextPrivate::dump()
-{
- dump(0);
-}
-
-void QmlContextPrivate::dump(int depth)
-{
- QByteArray ba(depth * 4, ' ');
- if (parent)
- parent->d_func()->dump(depth + 1);
-}
-
void QmlContextPrivate::destroyed(ContextGuard *guard)
{
Q_Q(QmlContext);
@@ -382,8 +370,8 @@ void QmlContext::setContextProperty(const QString &name, const QVariant &value)
if (d->notifyIndex == -1)
d->notifyIndex = this->metaObject()->methodCount();
- if (QmlMetaType::isObject(value.userType())) {
- QObject *o = QmlMetaType::toQObject(value);
+ if (d->engine && QmlEnginePrivate::get(d->engine)->isObject(value.userType())) {
+ QObject *o = *(QObject **)value.constData();
setContextProperty(name, o);
} else {
diff --git a/src/declarative/qml/qmlcontext_p.h b/src/declarative/qml/qmlcontext_p.h
index cc8fcc6..7f9be0f 100644
--- a/src/declarative/qml/qmlcontext_p.h
+++ b/src/declarative/qml/qmlcontext_p.h
@@ -101,9 +101,6 @@ public:
void init();
- void dump();
- void dump(int depth);
-
void invalidateEngines();
void refreshExpressions();
QSet<QmlContext *> childContexts;