core (XMLUI): BoolWidget now accept real boolean for value
This commit is contained in:
parent
9bd81494d1
commit
3be53bdc69
1 changed files with 3 additions and 1 deletions
|
|
@ -579,7 +579,9 @@ class BoolWidget(InputWidget):
|
|||
type = 'bool'
|
||||
|
||||
def __init__(self, xmlui, value='false', name=None, parent=None):
|
||||
if value == '0':
|
||||
if isinstance(value, bool):
|
||||
value = 'true' if value else 'false'
|
||||
elif value == '0':
|
||||
value='false'
|
||||
elif value == '1':
|
||||
value='true'
|
||||
|
|
|
|||
Loading…
Reference in a new issue