buildRecordingRadioListTile function

Widget buildRecordingRadioListTile(
  1. RadioListTile radio,
  2. dynamic widget
)

Implementation

Widget buildRecordingRadioListTile(RadioListTile radio, widget) {
  return RadioListTile(
    title: radio.title,
    subtitle: radio.subtitle,
    isThreeLine: radio.isThreeLine,
    dense: radio.dense,
    contentPadding: radio.contentPadding,
    secondary: radio.secondary,
    selected: radio.selected,
    controlAffinity: radio.controlAffinity,
    autofocus: radio.autofocus,
    shape: radio.shape,
    tileColor: radio.tileColor,
    selectedTileColor: radio.selectedTileColor,
    activeColor: radio.activeColor,
    fillColor: radio.fillColor,
    hoverColor: radio.hoverColor,
    overlayColor: radio.overlayColor,
    splashRadius: radio.splashRadius,
    materialTapTargetSize: radio.materialTapTargetSize,
    visualDensity: radio.visualDensity,
    focusNode: radio.focusNode,
    enableFeedback: radio.enableFeedback,
    value: radio.value,
    groupValue: radio.groupValue,
    onChanged: (value) async {
      debugPrint(
        '[SelfTest] Recording radio change for "${widget.id}": $value',
      );
      await SelfTestManager().recordTap(widget.id);
      if (radio.onChanged != null) {
        radio.onChanged!(value);
      } else {
        widget.onTap?.call();
      }
    },
    toggleable: radio.toggleable,
  );
}