- `Scaffold.of(context).showBottomSheet(widget);`
- Returns an object with .closed Future and .close() method.
- Uses a StateRoute to handle back button.
- Take the Navigator logic out of the BottomSheet widget.
- Support showing a sheet while an old one is going away.
- Add Navigator.remove().
PageRoute is now MaterialPageRoute.
This also changes the following:
- Now the HeroController is a Navigator observer, rather than a feature
of HeroPageRoutes, which are gone. This means heroes can work between
any kind of ModalRoute now.
- ModalPageRoute is moved from modal_barrier.dart to routes.dart.
- It allows routes to opt-out of their modal barrier being a shortcut to
popping the route.
- Features of PageRoute that aren't Material-specific get promoted to
ModalRoute features: storage, the subtree key, offstageness...
The AnimatedModalBarrier is still a ModalRoute feature.
- force the time dilation to 1.0 for the Widget tests, so that a local
change doesn't break all the tests during development.
- add missing license block to all the files.
- set ui.window.onBeginFrame to null when you use WidgetTester, so that
the engine doesn't trigger any confusing frames after our fake frames.
Factored OverlayRoute out of the modal and persistent bottom sheet clases, since the bottom sheet classes need to drive the performance.
Added a bottom sheet to the stocks demo: long-press on a stock shows a modal bottom sheet.
Made AnimatedModalBarrier public.