copyWith method

DialogTheme copyWith (
  1. {Color backgroundColor,
  2. double elevation,
  3. ShapeBorder shape,
  4. TextStyle titleTextStyle,
  5. TextStyle contentTextStyle}
)

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

Implementation

DialogTheme copyWith({
  Color backgroundColor,
  double elevation,
  ShapeBorder shape,
  TextStyle titleTextStyle,
  TextStyle contentTextStyle,
}) {
  return DialogTheme(
    backgroundColor: backgroundColor ?? this.backgroundColor,
    elevation: elevation ?? this.elevation,
    shape: shape ?? this.shape,
    titleTextStyle: titleTextStyle ?? this.titleTextStyle,
    contentTextStyle: contentTextStyle ?? this.contentTextStyle,
  );
}