summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/declarative/debugger/qmldebug.cpp1
-rw-r--r--src/declarative/qml/qmlenginedebug.cpp9
-rw-r--r--src/declarative/qml/qmlenginedebug_p.h1
3 files changed, 9 insertions, 2 deletions
diff --git a/src/declarative/debugger/qmldebug.cpp b/src/declarative/debugger/qmldebug.cpp
index 8309ec6..9397bb9 100644
--- a/src/declarative/debugger/qmldebug.cpp
+++ b/src/declarative/debugger/qmldebug.cpp
@@ -103,6 +103,7 @@ void QmlEngineDebugPrivate::decode(QDataStream &ds, QmlDebugObjectReference &o,
ds >> data;
QmlDebugPropertyReference prop;
prop.m_name = data.name;
+ prop.m_binding = data.binding;
if (data.type == QmlEngineDebugServer::QmlObjectProperty::Basic)
prop.m_value = data.value;
else if (data.type == QmlEngineDebugServer::QmlObjectProperty::Object) {
diff --git a/src/declarative/qml/qmlenginedebug.cpp b/src/declarative/qml/qmlenginedebug.cpp
index 2b8aac3..c26f3b7 100644
--- a/src/declarative/qml/qmlenginedebug.cpp
+++ b/src/declarative/qml/qmlenginedebug.cpp
@@ -44,6 +44,8 @@
#include <QtCore/qmetaobject.h>
#include <QtDeclarative/qmlengine.h>
#include <QtDeclarative/qmlmetatype.h>
+#include <qmlmetaproperty.h>
+#include <qmlbinding.h>
#include "qmlcontext_p.h"
QT_BEGIN_NAMESPACE
@@ -73,7 +75,7 @@ QDataStream &operator>>(QDataStream &ds,
QDataStream &operator<<(QDataStream &ds,
const QmlEngineDebugServer::QmlObjectProperty &data)
{
- ds << (int)data.type << data.name << data.value;
+ ds << (int)data.type << data.name << data.value << data.binding;
return ds;
}
@@ -81,7 +83,7 @@ QDataStream &operator>>(QDataStream &ds,
QmlEngineDebugServer::QmlObjectProperty &data)
{
int type;
- ds >> type >> data.name >> data.value;
+ ds >> type >> data.name >> data.value >> data.binding;
data.type = (QmlEngineDebugServer::QmlObjectProperty::Type)type;
return ds;
}
@@ -95,6 +97,9 @@ QmlEngineDebugServer::propertyData(QObject *obj, int propIdx)
rv.type = QmlObjectProperty::Unknown;
rv.name = prop.name();
+ QmlBinding *binding = QmlMetaProperty(obj, rv.name).binding();
+ if (binding)
+ rv.binding = binding->expression();
if (prop.type() < QVariant::UserType) {
rv.type = QmlObjectProperty::Basic;
diff --git a/src/declarative/qml/qmlenginedebug_p.h b/src/declarative/qml/qmlenginedebug_p.h
index e85ab6f..87b2ffd 100644
--- a/src/declarative/qml/qmlenginedebug_p.h
+++ b/src/declarative/qml/qmlenginedebug_p.h
@@ -81,6 +81,7 @@ public:
Type type;
QString name;
QVariant value;
+ QString binding;
};
static void addEngine(QmlEngine *);