showDialog<T> method

Future<T?> showDialog<T>({
  1. required WidgetBuilder builder,
  2. bool barrierDismissible = true,
  3. bool useRootNavigator = true,
  4. RouteSettings? routeSettings,
})

Displays a Material dialog above the current contents of the app, with Material entrance and exit animations, modal barrier color, and modal barrier behavior (dialog is dismissible with a tap on the barrier).

Equivalent to material.showDialog.

Implementation

Future<T?> showDialog<T>({
  required material.WidgetBuilder builder,
  bool barrierDismissible: true,
  bool useRootNavigator: true,
  material.RouteSettings? routeSettings,
}) {
  return material.showDialog<T>(
    context: this,
    barrierDismissible: barrierDismissible,
    builder: builder,
    useRootNavigator: useRootNavigator,
    routeSettings: routeSettings,
  );
}