mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-08-05 04:54:04 -06: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:
|
||||
{
|
||||
if(value == "True")
|
||||
switch(propertyProvider.properties.value)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else if(value == "False")
|
||||
{
|
||||
return false;
|
||||
}
|
||||
else
|
||||
{
|
||||
return value;
|
||||
case "True":
|
||||
return true
|
||||
case "False":
|
||||
return false
|
||||
default:
|
||||
return propertyProvider.properties.value
|
||||
}
|
||||
}
|
||||
|
||||
onClicked: propertyProvider.setPropertyValue("value", !checked)
|
||||
|
||||
Rectangle
|
||||
{
|
||||
anchors
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue