onConfirmTap method

void onConfirmTap(
  1. BuildContext ctx,
  2. dynamic selectedValues,
  3. dynamic onConfirm(
    1. dynamic
    )?
)

Pops the dialog from the navigation stack and returns the selected values. Calls the onConfirm function if one was provided.

Implementation

void onConfirmTap(
    BuildContext ctx, dynamic selectedValues, Function(dynamic)? onConfirm) {
  Navigator.pop(ctx, selectedValues);
  if (onConfirm != null) {
    onConfirm(selectedValues);
  }
}