aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlpropertybinding_p.h
diff options
context:
space:
mode:
authorFabian Kosmale <fabian.kosmale@qt.io>2021-10-14 17:00:41 +0200
committerFabian Kosmale <fabian.kosmale@qt.io>2021-10-18 12:39:29 +0200
commit785addcd17c7988be90a2ca17599c12b07e4e170 (patch)
tree939b83778a8508f27e880a0b48b34bfee1ca9d61 /src/qml/qml/qqmlpropertybinding_p.h
parent728cc261a0cd644760d217b9ea22dce9f00676c9 (diff)
ParentChange: handle bindable properties
QQuickParentChange::actions was unable to handle new style properties. Fix this by using a QQmlAnyBinding create function instead of QQmlBinding. This required adding the necessary support for creation from a QQmlScriptString to QQmlProperyBinding and QQmlAnyBinding. Extra care had to be taken in reverseRewindHelper, which assumed that setting x/y/width/height would keep binding intact. We therefore use setValueBypassingBindings instead of the plain setter. Fixes: QTBUG-97480 Pick-to: 6.2 6.2.1 Change-Id: I0cc6d61c655d9d37846adf4b09fe103f507bb329 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'src/qml/qml/qqmlpropertybinding_p.h')
-rw-r--r--src/qml/qml/qqmlpropertybinding_p.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/qml/qml/qqmlpropertybinding_p.h b/src/qml/qml/qqmlpropertybinding_p.h
index c2af93869a..17f74d5675 100644
--- a/src/qml/qml/qqmlpropertybinding_p.h
+++ b/src/qml/qml/qqmlpropertybinding_p.h
@@ -129,6 +129,10 @@ public:
const QQmlRefPointer<QQmlContextData> &ctxt,
const QString &url, quint16 lineNumber,
QObject *target, QQmlPropertyIndex targetIndex);
+ static QUntypedPropertyBinding createFromScriptString(const QQmlPropertyData *property,
+ const QQmlScriptString& script, QObject *obj,
+ QQmlContext *ctxt, QObject *target,
+ QQmlPropertyIndex targetIndex);
static QUntypedPropertyBinding createFromBoundFunction(const QQmlPropertyData *pd, QV4::BoundFunction *function,
QObject *obj, const QQmlRefPointer<QQmlContextData> &ctxt,