Commit 1065ead5 authored by Thomas Hartmann's avatar Thomas Hartmann
Browse files

QmlDesigner.PropertyEditor: Do not setup the color in onCompleted



Instead we connect to the selectionChanged signal and do the setup there.

Change-Id: Ia44887fa794c9726b3c4111e1b1f37ba2baaafc5
Reviewed-by: default avatarThomas Hartmann <Thomas.Hartmann@digia.com>
parent 5d0e8f5f
...@@ -105,9 +105,18 @@ Column { ...@@ -105,9 +105,18 @@ Column {
buttonRow.checkedIndex = buttonRow.initalChecked buttonRow.checkedIndex = buttonRow.initalChecked
} }
Connections {
target: modelNodeBackend
onSelectionChanged: {
if (supportGradient && gradientLine.hasGradient) {
colorEditor.color = gradientLine.currentColor
} else {
colorEditor.color = colorEditor.value
}
}
}
Component.onCompleted: { Component.onCompleted: {
colorEditor.color = gradientLine.currentColor
isCompleted= true isCompleted= true
} }
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment