Merge branch '5.0'

This commit is contained in:
Ghostkeeper 2022-05-09 17:48:50 +02:00
commit 12901e351e
No known key found for this signature in database
GPG Key ID: 68F39EA88EEED5FF
9 changed files with 26 additions and 11 deletions

View File

@ -90,6 +90,7 @@ UM.TooltipArea
{ {
anchors.fill: parent anchors.fill: parent
borderColor: (textFieldWithUnit.hovered || textFieldWithUnit.activeFocus) ? UM.Theme.getColor("text_field_border_hovered") : "transparent"
liningColor: liningColor:
{ {
if (!textFieldWithUnit.enabled) if (!textFieldWithUnit.enabled)
@ -109,7 +110,7 @@ UM.TooltipArea
// Validation is OK. // Validation is OK.
if (textFieldWithUnit.hovered || textFieldWithUnit.activeFocus) if (textFieldWithUnit.hovered || textFieldWithUnit.activeFocus)
{ {
return UM.Theme.getColor("border_main") return UM.Theme.getColor("text_field_border_hovered")
} }
return UM.Theme.getColor("border_field_light") return UM.Theme.getColor("border_field_light")
} }

View File

@ -129,7 +129,8 @@ Item
background: UM.UnderlineBackground background: UM.UnderlineBackground
{ {
id: backgroundItem id: backgroundItem
liningColor: intentSelection.hovered ? UM.Theme.getColor("border_main") : UM.Theme.getColor("border_field_light") borderColor: intentSelection.hovered ? UM.Theme.getColor("text_field_border_hovered") : "transparent"
liningColor: intentSelection.hovered ? UM.Theme.getColor("text_field_border_hovered") : UM.Theme.getColor("border_field_light")
} }
UM.SimpleButton UM.SimpleButton

View File

@ -125,15 +125,16 @@ SettingItem
} }
return UM.Theme.getColor("setting_control") return UM.Theme.getColor("setting_control")
} }
borderColor: (base.hovered || control.activeFocus) ? UM.Theme.getSize("text_field_border_hovered") : "transparent"
liningColor: liningColor:
{ {
if (!enabled) if (!enabled)
{ {
return UM.Theme.getColor("setting_control_disabled_border") return UM.Theme.getColor("setting_control_disabled_border")
} }
if (control.hovered || control.activeFocus) if (base.hovered || control.activeFocus)
{ {
return UM.Theme.getColor("border_main") return UM.Theme.getColor("text_field_border_hovered")
} }
return UM.Theme.getColor("border_field_light") return UM.Theme.getColor("border_field_light")
} }

View File

@ -126,15 +126,16 @@ SettingItem
} }
return UM.Theme.getColor("setting_control") return UM.Theme.getColor("setting_control")
} }
borderColor: (base.hovered || control.activeFocus) ? UM.Theme.getColor("text_field_border_hovered") : "transparent"
liningColor: liningColor:
{ {
if (!enabled) if (!enabled)
{ {
return UM.Theme.getColor("setting_control_disabled_border") return UM.Theme.getColor("setting_control_disabled_border")
} }
if (control.hovered || control.activeFocus) if (base.hovered || control.activeFocus)
{ {
return UM.Theme.getColor("border_main") return UM.Theme.getColor("text_field_border_hovered")
} }
return UM.Theme.getColor("border_field_light") return UM.Theme.getColor("border_field_light")
} }

View File

@ -32,6 +32,7 @@ SettingItem
anchors.fill: parent anchors.fill: parent
borderColor: (hovered || input.activeFocus) ? UM.Theme.getColor("text_field_border_hovered") : "transparent"
liningColor: liningColor:
{ {
if(!enabled) if(!enabled)

View File

@ -32,8 +32,13 @@ ComboBox
State State
{ {
name: "highlighted" name: "highlighted"
when: control.hovered || control.activeFocus when: base.hovered || control.hovered || control.activeFocus
PropertyChanges { target: background; liningColor: UM.Theme.getColor("border_main")} PropertyChanges
{
target: background
borderColor: UM.Theme.getColor("text_field_border_hovered")
liningColor: UM.Theme.getColor("text_field_border_hovered")
}
} }
] ]

View File

@ -47,7 +47,12 @@ TextField
{ {
name: "hovered" name: "hovered"
when: control.hovered || control.activeFocus when: control.hovered || control.activeFocus
PropertyChanges { target: backgroundRectangle; liningColor: UM.Theme.getColor("text_field_border_hovered")} PropertyChanges
{
target: backgroundRectangle
liningColor: UM.Theme.getColor("text_field_border_hovered")
borderColor: UM.Theme.getColor("text_field_border_hovered")
}
} }
] ]

View File

@ -15,7 +15,7 @@
"accent_2": [16, 70, 156, 255], "accent_2": [16, 70, 156, 255],
"border_main": [118, 118, 119, 255], "border_main": [118, 118, 119, 255],
"border_accent_1": [255, 255, 255, 255], "border_accent_1": [255, 255, 255, 255],
"border_accent_2": [16, 70, 156, 255], "border_accent_2": [243, 243, 243, 255],
"border_field": [57, 57, 58, 255], "border_field": [57, 57, 58, 255],
"text_default": [255, 255, 255, 255], "text_default": [255, 255, 255, 255],

View File

@ -363,7 +363,7 @@
"text_field": "background_1", "text_field": "background_1",
"text_field_border": [180, 180, 180, 255], "text_field_border": [180, 180, 180, 255],
"text_field_border_hovered": "border_main", "text_field_border_hovered": "border_accent_2",
"text_field_border_disabled": "background_2", "text_field_border_disabled": "background_2",
"text_field_text": "text_default", "text_field_text": "text_default",
"text_field_text_disabled": "text_disabled", "text_field_text_disabled": "text_disabled",