forked from firka/flutter
Auto-format Framework (#160545)
This auto-formats all *.dart files in the repository outside of the `engine` subdirectory and enforces that these files stay formatted with a presubmit check. **Reviewers:** Please carefully review all the commits except for the one titled "formatted". The "formatted" commit was auto-generated by running `dev/tools/format.sh -a -f`. The other commits were hand-crafted to prepare the repo for the formatting change. I recommend reviewing the commits one-by-one via the "Commits" tab and avoiding Github's "Files changed" tab as it will likely slow down your browser because of the size of this PR. --------- Co-authored-by: Kate Lovett <katelovett@google.com> Co-authored-by: LongCatIsLooong <31859944+LongCatIsLooong@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
8e0993eda8
commit
5491c8c146
@@ -13,9 +13,7 @@ class RefreshIndicatorExampleApp extends StatelessWidget {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return const MaterialApp(
|
||||
home: RefreshIndicatorExample(),
|
||||
);
|
||||
return const MaterialApp(home: RefreshIndicatorExample());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -32,9 +30,7 @@ class _RefreshIndicatorExampleState extends State<RefreshIndicatorExample> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: const Text('RefreshIndicator Sample'),
|
||||
),
|
||||
appBar: AppBar(title: const Text('RefreshIndicator Sample')),
|
||||
body: RefreshIndicator(
|
||||
key: _refreshIndicatorKey,
|
||||
color: Colors.white,
|
||||
@@ -49,9 +45,7 @@ class _RefreshIndicatorExampleState extends State<RefreshIndicatorExample> {
|
||||
child: ListView.builder(
|
||||
itemCount: 25,
|
||||
itemBuilder: (BuildContext context, int index) {
|
||||
return ListTile(
|
||||
title: Text('Item $index'),
|
||||
);
|
||||
return ListTile(title: Text('Item $index'));
|
||||
},
|
||||
),
|
||||
),
|
||||
|
||||
@@ -15,7 +15,9 @@ class RefreshIndicatorExampleApp extends StatelessWidget {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return MaterialApp(
|
||||
scrollBehavior: const MaterialScrollBehavior().copyWith(dragDevices: PointerDeviceKind.values.toSet()),
|
||||
scrollBehavior: const MaterialScrollBehavior().copyWith(
|
||||
dragDevices: PointerDeviceKind.values.toSet(),
|
||||
),
|
||||
home: const RefreshIndicatorExample(),
|
||||
);
|
||||
}
|
||||
@@ -27,9 +29,7 @@ class RefreshIndicatorExample extends StatelessWidget {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: const Text('RefreshIndicator Sample'),
|
||||
),
|
||||
appBar: AppBar(title: const Text('RefreshIndicator Sample')),
|
||||
body: RefreshIndicator(
|
||||
color: Colors.white,
|
||||
backgroundColor: Colors.blue,
|
||||
@@ -59,10 +59,7 @@ class RefreshIndicatorExample extends StatelessWidget {
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: <Widget>[
|
||||
Text(
|
||||
'Pull down here',
|
||||
style: Theme.of(context).textTheme.headlineMedium,
|
||||
),
|
||||
Text('Pull down here', style: Theme.of(context).textTheme.headlineMedium),
|
||||
const Text("RefreshIndicator won't trigger"),
|
||||
],
|
||||
),
|
||||
@@ -90,8 +87,8 @@ class RefreshIndicatorExample extends StatelessWidget {
|
||||
title: Text('Pull down here'),
|
||||
subtitle: Text("Refresh indicator won't trigger"),
|
||||
);
|
||||
}
|
||||
)
|
||||
},
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
|
||||
@@ -13,9 +13,7 @@ class RefreshIndicatorExampleApp extends StatelessWidget {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return const MaterialApp(
|
||||
home: RefreshIndicatorExample(),
|
||||
);
|
||||
return const MaterialApp(home: RefreshIndicatorExample());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -32,9 +30,7 @@ class _RefreshIndicatorExampleState extends State<RefreshIndicatorExample> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: const Text('RefreshIndicator.noSpinner Sample'),
|
||||
),
|
||||
appBar: AppBar(title: const Text('RefreshIndicator.noSpinner Sample')),
|
||||
body: Stack(
|
||||
children: <Widget>[
|
||||
RefreshIndicator.noSpinner(
|
||||
@@ -70,8 +66,8 @@ class _RefreshIndicatorExampleState extends State<RefreshIndicatorExample> {
|
||||
title: const Text('Pull down here'),
|
||||
subtitle: const Text('A custom refresh indicator will be shown'),
|
||||
);
|
||||
}
|
||||
)
|
||||
},
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -88,7 +84,7 @@ class _RefreshIndicatorExampleState extends State<RefreshIndicatorExample> {
|
||||
),
|
||||
),
|
||||
),
|
||||
]
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user