Corrected the "Routes can return a value" example (#7638)

This commit is contained in:
Hans Muller 2017-01-25 15:00:18 -08:00 committed by GitHub
parent 1426ef9944
commit 9cfcd3fdec

View File

@ -368,9 +368,9 @@ typedef bool RoutePredicate(Route<dynamic> route);
/// bool value = await Navigator.of(context).push(new MaterialPageRoute<bool>( /// bool value = await Navigator.of(context).push(new MaterialPageRoute<bool>(
/// builder: (BuildContext context) { /// builder: (BuildContext context) {
/// return new Center( /// return new Center(
/// child: new FlatButton( /// child: new GestureDetector(
/// child: new Text('OK'), /// child: new Text('OK'),
/// onPressed: () { Navigator.of(context).pop(true); } /// onTap: () { Navigator.of(context).pop(true); }
/// ), /// ),
/// ); /// );
/// } /// }