mirror of
https://github.com/alicevision/Meshroom.git
synced 2025-08-06 10:18:42 +02:00
[GraphEditor] Internal Custom Color Picker disabled when node is locked
This commit is contained in:
parent
6791f02f2d
commit
1cdcc6dd78
1 changed files with 5 additions and 3 deletions
|
@ -289,6 +289,7 @@ RowLayout {
|
||||||
id: color_checkbox
|
id: color_checkbox
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
checked: node && node.color === "" ? false : true
|
checked: node && node.color === "" ? false : true
|
||||||
|
checkable: root.editable
|
||||||
text: "Custom Color"
|
text: "Custom Color"
|
||||||
onClicked: {
|
onClicked: {
|
||||||
if (checked) {
|
if (checked) {
|
||||||
|
@ -302,9 +303,9 @@ RowLayout {
|
||||||
id: colorText
|
id: colorText
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
implicitWidth: 100
|
implicitWidth: 100
|
||||||
enabled: color_checkbox.checked
|
enabled: color_checkbox.checked && root.editable
|
||||||
visible: enabled
|
visible: color_checkbox.checked
|
||||||
text: enabled ? attribute.value : ""
|
text: color_checkbox.checked ? attribute.value : ""
|
||||||
selectByMouse: true
|
selectByMouse: true
|
||||||
onEditingFinished: setTextFieldAttribute(text)
|
onEditingFinished: setTextFieldAttribute(text)
|
||||||
onAccepted: setTextFieldAttribute(text)
|
onAccepted: setTextFieldAttribute(text)
|
||||||
|
@ -322,6 +323,7 @@ RowLayout {
|
||||||
color: color_checkbox.checked ? attribute.value : ""
|
color: color_checkbox.checked ? attribute.value : ""
|
||||||
|
|
||||||
MouseArea {
|
MouseArea {
|
||||||
|
enabled: root.editable
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
onClicked: colorDialog.open()
|
onClicked: colorDialog.open()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue