copyWith method
CustomPopupButtonTheme
copyWith({
- Color? backgroundColor,
- Color? foregroundColor,
- double? padding,
- double? spacing,
- double? borderRadius,
override
Creates a copy of this theme extension with the given fields replaced by the non-null parameter values.
Implementation
@override
CustomPopupButtonTheme copyWith({
Color? backgroundColor,
Color? foregroundColor,
double? padding,
double? spacing,
double? borderRadius,
}) {
return CustomPopupButtonTheme(
backgroundColor: backgroundColor ?? this.backgroundColor,
foregroundColor: foregroundColor ?? this.foregroundColor,
padding: padding ?? this.padding,
spacing: spacing ?? this.spacing,
borderRadius: borderRadius ?? this.borderRadius,
);
}