Add explanation about Navigator to showDialog doc (#14666)

* add explanation about navigator to showDialog doc

* update doc by review
This commit is contained in:
najeira
2018-02-15 10:16:34 +09:00
committed by Ian Hickson
parent b2af326046
commit 576191792a

View File

@@ -467,6 +467,11 @@ class _DialogRoute<T> extends PopupRoute<T> {
/// Returns a [Future] that resolves to the value (if any) that was passed to
/// [Navigator.pop] when the dialog was closed.
///
/// The dialog route created by this method is pushed to the root navigator.
/// If the application has multiple [Navigator] objects, it may be necessary to
/// call `Navigator.of(context, rootNavigator: true).pop(result)` to close the
/// dialog rather just 'Navigator.pop(context, result)`.
///
/// See also:
/// * [AlertDialog], for dialogs that have a row of buttons below a body.
/// * [SimpleDialog], which handles the scrolling of the contents and does