fix bool param initialisation

This commit is contained in:
Michael Zanetti 2018-11-10 17:02:49 +01:00
parent 4584791a62
commit a3f704a1dc
2 changed files with 6 additions and 1 deletions

View File

@ -89,6 +89,12 @@ ItemDelegate {
id: boolComponent
Switch {
checked: root.param.value === true
Component.onCompleted: {
if (root.param.value === undefined) {
root.param.value = checked;
}
}
onClicked: {
root.param.value = checked;
}

View File

@ -131,5 +131,4 @@ Page {
}
}
}
}