Future showDialog({BuildContext context, Widget child })

Displays a dialog above the current contents of the app.

This function typically receives a Dialog widget as its child argument. Content below the dialog is dimmed with a ModalBarrier.

Returns a Future that resolves to the value (if any) that was passed to Navigator.pop when the dialog was closed.

See also:

Source

Future<dynamic/*=T*/> showDialog/*<T>*/({ BuildContext context, Widget child }) {
  return Navigator.push(context, new _DialogRoute<dynamic/*=T*/>(
    child: child,
    theme: Theme.of(context, shadowThemeOnly: true),
  ));
}