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

Update the Scaffold examples; use the new button classes (#61394)

parent 88a78d66
...@@ -1111,7 +1111,7 @@ class Scaffold extends StatefulWidget { ...@@ -1111,7 +1111,7 @@ class Scaffold extends StatefulWidget {
/// A set of buttons that are displayed at the bottom of the scaffold. /// A set of buttons that are displayed at the bottom of the scaffold.
/// ///
/// Typically this is a list of [FlatButton] widgets. These buttons are /// Typically this is a list of [TextButton] widgets. These buttons are
/// persistently visible, even if the [body] of the scaffold scrolls. /// persistently visible, even if the [body] of the scaffold scrolls.
/// ///
/// These widgets will be wrapped in a [ButtonBar]. /// These widgets will be wrapped in a [ButtonBar].
...@@ -1153,7 +1153,7 @@ class Scaffold extends StatefulWidget { ...@@ -1153,7 +1153,7 @@ class Scaffold extends StatefulWidget {
/// key: _scaffoldKey, /// key: _scaffoldKey,
/// appBar: AppBar(title: const Text('Drawer Demo')), /// appBar: AppBar(title: const Text('Drawer Demo')),
/// body: Center( /// body: Center(
/// child: RaisedButton( /// child: ElevatedButton(
/// onPressed: _openDrawer, /// onPressed: _openDrawer,
/// child: const Text('Open Drawer'), /// child: const Text('Open Drawer'),
/// ), /// ),
...@@ -1164,7 +1164,7 @@ class Scaffold extends StatefulWidget { ...@@ -1164,7 +1164,7 @@ class Scaffold extends StatefulWidget {
/// mainAxisAlignment: MainAxisAlignment.center, /// mainAxisAlignment: MainAxisAlignment.center,
/// children: <Widget>[ /// children: <Widget>[
/// const Text('This is the Drawer'), /// const Text('This is the Drawer'),
/// RaisedButton( /// ElevatedButton(
/// onPressed: _closeDrawer, /// onPressed: _closeDrawer,
/// child: const Text('Close Drawer'), /// child: const Text('Close Drawer'),
/// ), /// ),
...@@ -1213,7 +1213,7 @@ class Scaffold extends StatefulWidget { ...@@ -1213,7 +1213,7 @@ class Scaffold extends StatefulWidget {
/// key: _scaffoldKey, /// key: _scaffoldKey,
/// appBar: AppBar(title: Text('Drawer Demo')), /// appBar: AppBar(title: Text('Drawer Demo')),
/// body: Center( /// body: Center(
/// child: RaisedButton( /// child: ElevatedButton(
/// onPressed: _openEndDrawer, /// onPressed: _openEndDrawer,
/// child: Text('Open End Drawer'), /// child: Text('Open End Drawer'),
/// ), /// ),
...@@ -1224,7 +1224,7 @@ class Scaffold extends StatefulWidget { ...@@ -1224,7 +1224,7 @@ class Scaffold extends StatefulWidget {
/// mainAxisAlignment: MainAxisAlignment.center, /// mainAxisAlignment: MainAxisAlignment.center,
/// children: <Widget>[ /// children: <Widget>[
/// const Text('This is the Drawer'), /// const Text('This is the Drawer'),
/// RaisedButton( /// ElevatedButton(
/// onPressed: _closeEndDrawer, /// onPressed: _closeEndDrawer,
/// child: const Text('Close Drawer'), /// child: const Text('Close Drawer'),
/// ), /// ),
...@@ -1386,7 +1386,7 @@ class Scaffold extends StatefulWidget { ...@@ -1386,7 +1386,7 @@ class Scaffold extends StatefulWidget {
/// @override /// @override
/// Widget build(BuildContext context) { /// Widget build(BuildContext context) {
/// return Center( /// return Center(
/// child: RaisedButton( /// child: ElevatedButton(
/// child: Text('SHOW A SNACKBAR'), /// child: Text('SHOW A SNACKBAR'),
/// onPressed: () { /// onPressed: () {
/// Scaffold.of(context).showSnackBar( /// Scaffold.of(context).showSnackBar(
...@@ -1421,7 +1421,7 @@ class Scaffold extends StatefulWidget { ...@@ -1421,7 +1421,7 @@ class Scaffold extends StatefulWidget {
/// // can refer to the Scaffold with Scaffold.of(). /// // can refer to the Scaffold with Scaffold.of().
/// builder: (BuildContext context) { /// builder: (BuildContext context) {
/// return Center( /// return Center(
/// child: RaisedButton( /// child: ElevatedButton(
/// child: Text('SHOW A SNACKBAR'), /// child: Text('SHOW A SNACKBAR'),
/// onPressed: () { /// onPressed: () {
/// Scaffold.of(context).showSnackBar(SnackBar( /// Scaffold.of(context).showSnackBar(SnackBar(
...@@ -1966,7 +1966,7 @@ class ScaffoldState extends State<Scaffold> with TickerProviderStateMixin { ...@@ -1966,7 +1966,7 @@ class ScaffoldState extends State<Scaffold> with TickerProviderStateMixin {
/// ```dart /// ```dart
/// Widget build(BuildContext context) { /// Widget build(BuildContext context) {
/// return Center( /// return Center(
/// child: RaisedButton( /// child: ElevatedButton(
/// child: const Text('showBottomSheet'), /// child: const Text('showBottomSheet'),
/// onPressed: () { /// onPressed: () {
/// Scaffold.of(context).showBottomSheet<void>( /// Scaffold.of(context).showBottomSheet<void>(
...@@ -1980,7 +1980,7 @@ class ScaffoldState extends State<Scaffold> with TickerProviderStateMixin { ...@@ -1980,7 +1980,7 @@ class ScaffoldState extends State<Scaffold> with TickerProviderStateMixin {
/// mainAxisSize: MainAxisSize.min, /// mainAxisSize: MainAxisSize.min,
/// children: <Widget>[ /// children: <Widget>[
/// const Text('BottomSheet'), /// const Text('BottomSheet'),
/// RaisedButton( /// ElevatedButton(
/// child: const Text('Close BottomSheet'), /// child: const Text('Close BottomSheet'),
/// onPressed: () => Navigator.pop(context), /// onPressed: () => Navigator.pop(context),
/// ) /// )
......
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