call method

  1. @override
Object? call(
  1. Interpreter interpreter,
  2. List<Object?> arguments,
  3. Map<Symbol, Object?> namedArguments
)
override

Implementation

@override
Object? call(Interpreter interpreter, List<Object?> arguments,
    Map<Symbol, Object?> namedArguments) {
  Color? primary;
  var primaryParsed = namedArguments[const Symbol('primary')];
  if (primaryParsed != null) {
    primary = primaryParsed as Color;
  }
  Color? shadowColor;
  var shadowColorParsed = namedArguments[const Symbol('shadowColor')];
  if (shadowColorParsed != null) {
    shadowColor = shadowColorParsed as Color;
  }
  double? elevation = parseDouble(namedArguments[const Symbol('elevation')]);
  TextStyle? textStyle;
  var textStyleParsed = namedArguments[const Symbol('textStyle')];
  if (textStyleParsed != null) {
    textStyle = textStyleParsed as TextStyle;
  }
  EdgeInsetsGeometry? padding;
  var paddingParsed = namedArguments[const Symbol('padding')];
  if (paddingParsed != null) {
    padding = paddingParsed as EdgeInsetsGeometry;
  }
  BorderSide? side;
  var sideParsed = namedArguments[const Symbol('side')];
  if (sideParsed != null) {
    side = sideParsed as BorderSide;
  }
  Size? minimumSize;
  var minimumSizeParsed = namedArguments[const Symbol('minimumSize')];
  if (minimumSizeParsed != null) {
    minimumSize = minimumSizeParsed as Size;
  }
  Size? maximumSize;
  var maximumSizeParsed = namedArguments[const Symbol('maximumSize')];
  if (maximumSizeParsed != null) {
    maximumSize = maximumSizeParsed as Size;
  }
  Size? fixedSize;
  var fixedSizeParsed = namedArguments[const Symbol('fixedSize')];
  if (fixedSizeParsed != null) {
    fixedSize = fixedSizeParsed as Size;
  }
  OutlinedBorder? shape;
  var shapeParsed = namedArguments[const Symbol('shape')];
  if (shapeParsed != null) {
    shape = shapeParsed as OutlinedBorder;
  }
  AlignmentGeometry? alignment;
  var alignmentParsed = namedArguments[const Symbol('alignment')];
  if (alignmentParsed != null) {
    alignment = alignmentParsed as AlignmentGeometry;
  }
  return ElevatedButton.styleFrom(
      primary: primary,
      shadowColor: shadowColor,
      elevation: elevation,
      textStyle: textStyle,
      alignment: alignment,
      side: side,
      shape: shape,
      minimumSize: minimumSize,
      maximumSize: maximumSize,
      fixedSize: fixedSize,
      padding: padding);
}