mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-12-04 08:11:09 -07:00
Make SettingCheckBox properly handle the value
This commit is contained in:
parent
5b31634d3c
commit
06432c3b0b
1 changed files with 9 additions and 10 deletions
|
|
@ -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…
Add table
Add a link
Reference in a new issue