📅  最后修改于: 2022-03-11 14:57:44.012000             🧑  作者: Mango
MergeSemantics(
child: ListTile(
title: Text('Lights'),
trailing: CupertinoSwitch(
value: _lights,
onChanged: (bool value) { setState(() { _lights = value; }); },
),
onTap: () { setState(() { _lights = !_lights; }); },
),
)