Unverified Commit cdb82fce authored by Hans Muller's avatar Hans Muller Committed by GitHub

Put the backdrop demo controls on the right (#16902)

parent b1330eff
...@@ -342,14 +342,7 @@ class _BackdropDemoState extends State<BackdropDemo> with SingleTickerProviderSt ...@@ -342,14 +342,7 @@ class _BackdropDemoState extends State<BackdropDemo> with SingleTickerProviderSt
}, },
), ),
); );
}).toList() }).toList();
..add(const SizedBox(height: 8.0))
..add(
new Align(
alignment: AlignmentDirectional.centerStart,
child: new BackButton(color: Colors.white.withOpacity(0.5))
),
);
return new Container( return new Container(
key: _backdropKey, key: _backdropKey,
...@@ -388,16 +381,18 @@ class _BackdropDemoState extends State<BackdropDemo> with SingleTickerProviderSt ...@@ -388,16 +381,18 @@ class _BackdropDemoState extends State<BackdropDemo> with SingleTickerProviderSt
return new Scaffold( return new Scaffold(
appBar: new AppBar( appBar: new AppBar(
elevation: 0.0, elevation: 0.0,
leading: new IconButton(
onPressed: _toggleBackdropPanelVisibility,
icon: new AnimatedIcon(
icon: AnimatedIcons.close_menu,
progress: _controller.view,
),
),
title: new BackdropTitle( title: new BackdropTitle(
listenable: _controller.view, listenable: _controller.view,
), ),
actions: <Widget>[
new IconButton(
onPressed: _toggleBackdropPanelVisibility,
icon: new AnimatedIcon(
icon: AnimatedIcons.close_menu,
progress: _controller.view,
),
),
],
), ),
body: new LayoutBuilder( body: new LayoutBuilder(
builder: _buildStack, builder: _buildStack,
......
...@@ -30,7 +30,6 @@ const List<String> _kUnsynchronizedDemos = const <String>[ ...@@ -30,7 +30,6 @@ const List<String> _kUnsynchronizedDemos = const <String>[
// These demos can't be backed out of by tapping a button whose // These demos can't be backed out of by tapping a button whose
// tooltip is 'Back'. // tooltip is 'Back'.
const List<String> _kSkippedDemos = const <String>[ const List<String> _kSkippedDemos = const <String>[
'Backdrop',
'Pull to refresh', 'Pull to refresh',
]; ];
......
...@@ -102,12 +102,6 @@ Future<Null> smokeDemo(WidgetTester tester, String routeName) async { ...@@ -102,12 +102,6 @@ Future<Null> smokeDemo(WidgetTester tester, String routeName) async {
await tester.pump(); await tester.pump();
await tester.pump(const Duration(milliseconds: 400)); await tester.pump(const Duration(milliseconds: 400));
// This demo's back button isn't initially visible.
if (routeName == '/material/backdrop') {
await tester.tap(find.byTooltip('Tap to dismiss'));
await tester.pumpAndSettle();
}
// Go back // Go back
await tester.pageBack(); await tester.pageBack();
await tester.pumpAndSettle(); await tester.pumpAndSettle();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment