mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-04-30 15:54:32 +08:00
Fix checkboxes not showing check marks when disabled.
Update checkboxes to align with new designs. Update SettingCheckBox to match checkbox styling. Remove duplicated styling inside cura-dark/theme.json CURA-8991
This commit is contained in:
parent
2ed68beb22
commit
a26b54f6e2
@ -11,7 +11,7 @@ SettingItem
|
|||||||
{
|
{
|
||||||
id: base
|
id: base
|
||||||
property var focusItem: control
|
property var focusItem: control
|
||||||
|
enabled: false
|
||||||
contents: MouseArea
|
contents: MouseArea
|
||||||
{
|
{
|
||||||
id: control
|
id: control
|
||||||
@ -98,7 +98,7 @@ SettingItem
|
|||||||
{
|
{
|
||||||
if(!enabled)
|
if(!enabled)
|
||||||
{
|
{
|
||||||
return UM.Theme.getColor("checkbox_border")
|
return UM.Theme.getColor("checkbox_border_disabled")
|
||||||
}
|
}
|
||||||
switch (propertyProvider.properties.validationState)
|
switch (propertyProvider.properties.validationState)
|
||||||
{
|
{
|
||||||
@ -116,7 +116,7 @@ SettingItem
|
|||||||
{
|
{
|
||||||
return UM.Theme.getColor("checkbox_border_hover")
|
return UM.Theme.getColor("checkbox_border_hover")
|
||||||
}
|
}
|
||||||
return UM.Theme.getColor("setting_control_border")
|
return UM.Theme.getColor("checkbox_border")
|
||||||
}
|
}
|
||||||
|
|
||||||
color: {
|
color: {
|
||||||
@ -138,7 +138,7 @@ SettingItem
|
|||||||
// Validation is OK.
|
// Validation is OK.
|
||||||
if (control.containsMouse || control.activeFocus)
|
if (control.containsMouse || control.activeFocus)
|
||||||
{
|
{
|
||||||
return UM.Theme.getColor("setting_control_highlight")
|
return UM.Theme.getColor("checkbox_hover")
|
||||||
}
|
}
|
||||||
return UM.Theme.getColor("checkbox")
|
return UM.Theme.getColor("checkbox")
|
||||||
}
|
}
|
||||||
@ -150,7 +150,7 @@ SettingItem
|
|||||||
height: UM.Theme.getSize("checkbox_mark").height
|
height: UM.Theme.getSize("checkbox_mark").height
|
||||||
width: UM.Theme.getSize("checkbox_mark").width
|
width: UM.Theme.getSize("checkbox_mark").width
|
||||||
sourceSize.height: width
|
sourceSize.height: width
|
||||||
color: !enabled ? UM.Theme.getColor("setting_control_disabled_text") : UM.Theme.getColor("setting_control_text");
|
color: !enabled ? UM.Theme.getColor("checkbox_mark_disabled") : UM.Theme.getColor("checkbox_mark");
|
||||||
source: UM.Theme.getIcon("Check", "low")
|
source: UM.Theme.getIcon("Check", "low")
|
||||||
opacity: control.checked ? 1 : 0
|
opacity: control.checked ? 1 : 0
|
||||||
Behavior on opacity { NumberAnimation { duration: 100; } }
|
Behavior on opacity { NumberAnimation { duration: 100; } }
|
||||||
|
@ -155,15 +155,6 @@
|
|||||||
"slider_handle": [255, 255, 255, 255],
|
"slider_handle": [255, 255, 255, 255],
|
||||||
"slider_handle_active": [68, 192, 255, 255],
|
"slider_handle_active": [68, 192, 255, 255],
|
||||||
|
|
||||||
"checkbox": "background_1",
|
|
||||||
"checkbox_hover": [43, 48, 52, 255],
|
|
||||||
"checkbox_border": "text_disabled",
|
|
||||||
"checkbox_border_hover": "border_main",
|
|
||||||
"checkbox_mark": "text_default",
|
|
||||||
"checkbox_square": "text_disabled",
|
|
||||||
"checkbox_text": "text_default",
|
|
||||||
"checkbox_disabled": "background_2",
|
|
||||||
|
|
||||||
"category_background": "background_3",
|
"category_background": "background_3",
|
||||||
|
|
||||||
"tooltip": "background_2",
|
"tooltip": "background_2",
|
||||||
|
@ -324,13 +324,16 @@
|
|||||||
"quality_slider_unavailable": [179, 179, 179, 255],
|
"quality_slider_unavailable": [179, 179, 179, 255],
|
||||||
"quality_slider_available": [0, 0, 0, 255],
|
"quality_slider_available": [0, 0, 0, 255],
|
||||||
|
|
||||||
"checkbox": [255, 255, 255, 255],
|
"checkbox": "background_1",
|
||||||
"checkbox_hover": "border_main",
|
"checkbox_hover": "background_1",
|
||||||
"checkbox_border": [180, 180, 180, 255],
|
|
||||||
"checkbox_border_hover": [25, 110, 240, 255],
|
|
||||||
"checkbox_mark": [35, 35, 35, 255],
|
|
||||||
"checkbox_disabled": "background_2",
|
"checkbox_disabled": "background_2",
|
||||||
"checkbox_text": [0, 12, 26, 255],
|
"checkbox_border": [180, 180, 180, 255],
|
||||||
|
"checkbox_border_hover": "border_main",
|
||||||
|
"checkbox_border_disabled": "text_disabled",
|
||||||
|
"checkbox_mark": "text_default",
|
||||||
|
"checkbox_mark_disabled": "text_disabled",
|
||||||
|
"checkbox_text": "text_default",
|
||||||
|
"checkbox_text_disabled": "text_disabled",
|
||||||
|
|
||||||
"category_background": "background_2",
|
"category_background": "background_2",
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user