copyWith method
SelectionBehavior
copyWith(
{ - bool? enable,
- Color? selectedColor,
- Color? unselectedColor,
- Color? selectedBorderColor,
- Color? unselectedBorderColor,
- double? selectedBorderWidth,
- double? unselectedBorderWidth,
- double? selectedOpacity,
- double? unselectedOpacity,
- bool? toggleSelection,
})
Implementation
SelectionBehavior copyWith({
bool? enable,
Color? selectedColor,
Color? unselectedColor,
Color? selectedBorderColor,
Color? unselectedBorderColor,
double? selectedBorderWidth,
double? unselectedBorderWidth,
double? selectedOpacity,
double? unselectedOpacity,
bool? toggleSelection,
}) {
return SelectionBehavior(
enable: enable ?? this.enable,
selectedColor: selectedColor ?? this.selectedColor,
unselectedColor: unselectedColor ?? this.unselectedColor,
selectedBorderColor: selectedBorderColor ?? this.selectedBorderColor,
unselectedBorderColor:
unselectedBorderColor ?? this.unselectedBorderColor,
selectedBorderWidth: selectedBorderWidth ?? this.selectedBorderWidth,
unselectedBorderWidth:
unselectedBorderWidth ?? this.unselectedBorderWidth,
selectedOpacity: selectedOpacity ?? this.selectedOpacity,
unselectedOpacity: unselectedOpacity ?? this.unselectedOpacity,
toggleSelection: toggleSelection ?? this.toggleSelection,
);
}