summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiikka Heikkinen <miikka.heikkinen@qt.io>2022-09-30 15:28:33 +0300
committerMiikka Heikkinen <miikka.heikkinen@qt.io>2022-09-30 13:14:05 +0000
commit243e473b4ccc8686910e30e13a3b89ada2815e86 (patch)
treec05f485f3edff7596ebfeb1692c46d7e895c0b6e
parent395e40b8f3a50a327b65ccce9cf2443d2c641924 (diff)
downloadqt-creator-243e473b4ccc8686910e30e13a3b89ada2815e86.tar.gz
QmlDesigner: Fix timeline check when committing dynamic property value
Timeline has to be recording for us to care about it at value commit. Otherwise, if there is timeline but it's not recording, we end up with soft assert and losing the dynamic typename, which causes isDynamic checks to fail later on that property. Change-Id: Ib63467ecc4fca1d14409d3c68bb3a5fcd13c10ce Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
-rw-r--r--src/plugins/qmldesigner/components/propertyeditor/dynamicpropertiesproxymodel.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/plugins/qmldesigner/components/propertyeditor/dynamicpropertiesproxymodel.cpp b/src/plugins/qmldesigner/components/propertyeditor/dynamicpropertiesproxymodel.cpp
index b5791ba287..2c0772a5e1 100644
--- a/src/plugins/qmldesigner/components/propertyeditor/dynamicpropertiesproxymodel.cpp
+++ b/src/plugins/qmldesigner/components/propertyeditor/dynamicpropertiesproxymodel.cpp
@@ -335,7 +335,8 @@ void DynamicPropertyRow::commitValue(const QVariant &value)
QByteArrayLiteral("DynamicPropertiesModel::commitValue"));
try {
QmlObjectNode objectNode = variantProperty.parentQmlObjectNode();
- if (view->currentState().isBaseState() && !objectNode.timelineIsActive()) {
+ if (view->currentState().isBaseState()
+ && !(objectNode.timelineIsActive() && objectNode.currentTimeline().isRecording())) {
if (variantProperty.value() != value)
variantProperty.setDynamicTypeNameAndValue(variantProperty.dynamicTypeName(), value);
} else {