Skip to content

Commit b5d1f98

Browse files
authored
Merge pull request #2401 from alicevision/dev/nodeHeaderSelectedColor
[ui] Selected node header set to base color
2 parents 4a4839a + 8c242cb commit b5d1f98

File tree

1 file changed

+16
-4
lines changed

1 file changed

+16
-4
lines changed

meshroom/ui/qml/GraphEditor/Node.qml

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -149,9 +149,21 @@ Item {
149149
Rectangle {
150150
anchors.fill: nodeContent
151151
anchors.margins: -border.width
152-
visible: root.mainSelected || root.hovered
153-
border.width: 2.5
154-
border.color: root.mainSelected ? activePalette.highlight : Qt.darker(activePalette.highlight, 1.5)
152+
visible: root.mainSelected || root.hovered || root.selected
153+
border.width: {
154+
if(root.mainSelected)
155+
return 3
156+
if(root.selected)
157+
return 2.5
158+
return 2
159+
}
160+
border.color: {
161+
if(root.mainSelected)
162+
return activePalette.highlight
163+
if(root.selected)
164+
return Qt.darker(activePalette.highlight, 1.2)
165+
return Qt.lighter(activePalette.base, 3)
166+
}
155167
opacity: 0.9
156168
radius: background.radius + border.width
157169
color: "transparent"
@@ -183,7 +195,7 @@ Item {
183195
id: header
184196
width: parent.width
185197
height: headerLayout.height
186-
color: root.mainSelected ? activePalette.highlight : root.selected ? Qt.darker(activePalette.highlight, 1.1): root.baseColor
198+
color: root.baseColor
187199
radius: background.radius
188200

189201
// Fill header's bottom radius

0 commit comments

Comments
 (0)