Skip to content

6c. Cell: Switch

i_82 edited this page Mar 26, 2018 · 1 revision

Switch cell is a plain cell with a UISwitch called cellSwitch inside.

Key Type Description Flags Default
negate Boolean if negate == true then cell.state = !cellSwitch.isOn Optional false
trueValue Any? if cell.state == true then cell.value = trueValue Optional true
falseValue Any? if cell.state == false then cell.value = falseValue Optional false
theme Key Description
tintColor cellSwitch.tintColor
thumbColor cellSwitch.thumbTintColor
value Type Description
Any? Correspond to the negate ? !cellSwitch.isOn : cellSwitch.isOn.
If exist, it will be replaced by trueValue or falseValue.

Example

{
    "default": true,
    "label": "Enabled",
    "cell": "Switch",
    "key": "switch1",
    "icon": "res/16.png"
}

Clone this wiki locally