TimeModelBinding constructor
TimeModelBinding({
- Key? key,
- required Time initialTime,
- required Widget child,
- required void onChange(),
- void onChangeDateTime()?,
- void onCancel()?,
- bool is24HrFormat = false,
- bool? displayHeader,
- Color? accentColor,
- bool ltrMode = true,
- Color? unselectedColor,
- String cancelText = 'cancel',
- String okText = 'ok',
- bool isOnValueChangeMode = false,
- Image? sunAsset,
- Image? moonAsset,
- bool blurredBackground = false,
- Color? backgroundColor,
- double? borderRadius,
- double? elevation,
- EdgeInsets? dialogInsetPadding,
- EdgeInsets? contentPadding,
- TimePickerInterval? minuteInterval,
- TimePickerInterval? secondInterval,
- bool? disableMinute,
- bool? disableHour,
- double? maxHour,
- double? maxMinute,
- double? maxSecond,
- double? minHour,
- double? minMinute,
- double? minSecond,
- String? hourLabel,
- String? minuteLabel,
- String? secondLabel,
- String amLabel = 'am',
- String pmLabel = 'pm',
- bool isInlineWidget = false,
- bool focusMinutePicker = false,
- TextStyle okStyle = const TextStyle(fontWeight: FontWeight.bold),
- TextStyle cancelStyle = const TextStyle(fontWeight: FontWeight.bold),
- TextStyle? hmsStyle,
- ButtonStyle? buttonStyle,
- ButtonStyle? cancelButtonStyle,
- double? buttonsSpacing,
- double? wheelHeight,
- double? wheelMagnification,
- bool hideButtons = false,
- bool disableAutoFocusToNextInput = false,
- double width = 0,
- double? height,
- bool showSecondSelector = false,
- bool showCancelButton = true,
- TimeOfDay? sunrise,
- TimeOfDay? sunset,
- int? duskSpanInMinutes,
Constructor for the Widget
Implementation
TimeModelBinding({
Key? key,
required this.initialTime,
required this.child,
required this.onChange,
this.onChangeDateTime,
this.onCancel,
this.is24HrFormat = false,
this.displayHeader,
this.accentColor,
this.ltrMode = true,
this.unselectedColor,
this.cancelText = 'cancel',
this.okText = 'ok',
this.isOnValueChangeMode = false,
this.sunAsset,
this.moonAsset,
this.blurredBackground = false,
Color? backgroundColor,
this.borderRadius,
this.elevation,
this.dialogInsetPadding,
this.contentPadding,
this.minuteInterval,
this.secondInterval,
this.disableMinute,
this.disableHour,
this.maxHour,
this.maxMinute,
this.maxSecond,
this.minHour,
this.minMinute,
this.minSecond,
this.hourLabel,
this.minuteLabel,
this.secondLabel,
this.amLabel = 'am',
this.pmLabel = 'pm',
this.isInlineWidget = false,
this.focusMinutePicker = false,
this.okStyle = const TextStyle(fontWeight: FontWeight.bold),
this.cancelStyle = const TextStyle(fontWeight: FontWeight.bold),
this.hmsStyle,
this.buttonStyle,
this.cancelButtonStyle,
this.buttonsSpacing,
double? wheelHeight,
double? wheelMagnification,
this.hideButtons = false,
this.disableAutoFocusToNextInput = false,
this.width = 0,
double? height,
this.showSecondSelector = false,
this.showCancelButton = true,
this.sunrise,
this.sunset,
this.duskSpanInMinutes,
}) : height = height ?? 260,
wheelHeight = wheelHeight ?? 100,
wheelMagnification = wheelMagnification ?? 1.0,
backgroundColor = backgroundColor ?? Colors.white,
super(key: key);