onCheckBox method

Checkbox onCheckBox({
  1. bool? value,
  2. ValueChanged<bool>? onChanged,
  3. Color? activeColor,
  4. bool? tristate,
  5. MaterialTapTargetSize? materialTapTargetSize,
})

Implementation

Checkbox onCheckBox({
  bool? value,
  ValueChanged<bool>? onChanged,
  Color? activeColor,
  bool? tristate,
  MaterialTapTargetSize? materialTapTargetSize,
}) {
  _checkValue = value ?? _checkValue;
  toggle = onChanged ?? toggle;
  this.activeColor = activeColor ?? this.activeColor;
  this.tristate = tristate ?? this.tristate;
  this.materialTapTargetSize =
      materialTapTargetSize ?? this.materialTapTargetSize;
  final oldWidget = _checkbox;
  _checkbox = null;
  final newWidget = checkbox;
  _checkbox = oldWidget;
  return newWidget;
}