mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-14 16:45:56 +08:00
Make SettingCheckBox properly handle the value
This commit is contained in:
parent
5b31634d3c
commit
06432c3b0b
@ -19,20 +19,19 @@ SettingItem
|
|||||||
|
|
||||||
property bool checked:
|
property bool checked:
|
||||||
{
|
{
|
||||||
if(value == "True")
|
switch(propertyProvider.properties.value)
|
||||||
{
|
{
|
||||||
return true;
|
case "True":
|
||||||
}
|
return true
|
||||||
else if(value == "False")
|
case "False":
|
||||||
{
|
return false
|
||||||
return false;
|
default:
|
||||||
}
|
return propertyProvider.properties.value
|
||||||
else
|
|
||||||
{
|
|
||||||
return value;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
onClicked: propertyProvider.setPropertyValue("value", !checked)
|
||||||
|
|
||||||
Rectangle
|
Rectangle
|
||||||
{
|
{
|
||||||
anchors
|
anchors
|
||||||
|
Loading…
x
Reference in New Issue
Block a user