copyWith method

SnackBarThemeData copyWith ({Color backgroundColor, Color actionTextColor, Color disabledActionTextColor, TextStyle contentTextStyle, double elevation, ShapeBorder shape, SnackBarBehavior behavior })

Creates a copy of this object with the given fields replaced with the new values.

Implementation

SnackBarThemeData copyWith({
  Color backgroundColor,
  Color actionTextColor,
  Color disabledActionTextColor,
  TextStyle contentTextStyle,
  double elevation,
  ShapeBorder shape,
  SnackBarBehavior behavior,
}) {
  return SnackBarThemeData(
    backgroundColor: backgroundColor ?? this.backgroundColor,
    actionTextColor: actionTextColor ?? this.actionTextColor,
    disabledActionTextColor: disabledActionTextColor ?? this.disabledActionTextColor,
    contentTextStyle: contentTextStyle ?? this.contentTextStyle,
    elevation: elevation ?? this.elevation,
    shape: shape ?? this.shape,
    behavior: behavior ?? this.behavior,
  );
}