showInputCalculator method

Future<double?> showInputCalculator(
  1. BuildContext context
)
inherited

Implementation

Future<double?> showInputCalculator(BuildContext context) async {
  final args = InputCalculatorArgs(
    title: title ?? '',
    initialValue: initialValue,
    boxDecoration: boxDecoration,
    appBarBackgroundColor: appBarBackgroundColor,
    operatorButtonColor: operatorButtonColor,
    operatorTextButtonColor: operatorTextButtonColor,
    normalButtonColor: normalButtonColor,
    normalTextButtonColor: normalTextButtonColor,
    doneButtonColor: doneButtonColor,
    doneTextButtonColor: doneTextButtonColor,
    allowNegativeResult: allowNegativeResult ?? true,
    theme: theme ?? CalculatorThemes.curve,
  );

  final result = await Navigator.of(context).push(
    MaterialPageRoute(builder: (context) => Calculator(args: args)),
  );

  return result;
}