QmlDesigner: Fix color property expression binding

Fix setting an expression on a color property via the binding editor by
using the actual expression instead of a quote stripped version of it.

Task-number: QDS-12919
Change-Id: I877b9f622158a5a88b4fe6add968ded4e691cb20
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
(cherry picked from commit 79e6c6809b)
This commit is contained in:
Henning Gruendl
2024-06-03 17:04:38 +02:00
committed by Thomas Hartmann
parent 1d04511e6f
commit e23121b142

View File

@@ -368,9 +368,9 @@ void PropertyEditorView::setExpressionOnObjectNode(const QmlObjectNode &constObj
}
}
if (qmlObjectNode.expression(name) != expression
if (qmlObjectNode.expression(name) != newExpression
|| !qmlObjectNode.propertyAffectedByCurrentState(name))
qmlObjectNode.setBindingProperty(name, expression);
qmlObjectNode.setBindingProperty(name, newExpression);
}
void PropertyEditorView::generateAliasForProperty(const ModelNode &modelNode, const QString &name)