feat: remove WillPopScope in category.dart

This commit is contained in:
zymxxxs
2019-11-08 13:07:18 +08:00
parent fa2e77687d
commit 8ccab6fe71

View File

@ -43,15 +43,6 @@ class _CategoryHome extends State<CategoryHome> {
searchCatOrWidget();
}
Future<bool> back() {
// if (catHistory.length == 1) {
// return Future<bool>.value(true);
// }
// catHistory.removeLast();
// searchCatOrWidget();
return Future<bool>.value(true);
}
void go(CommonItem cat) {
catHistory.add(cat);
searchCatOrWidget();
@ -93,17 +84,10 @@ class _CategoryHome extends State<CategoryHome> {
appBar: AppBar(
title: Text("$title"),
),
body: WillPopScope(
onWillPop: () {
return back();
},
child: ListView(
children: <Widget>[
_buildContent(),
],
),
// child: Container(color: Colors.blue,child: Text('123'),),
body: ListView(
children: <Widget>[
_buildContent(),
],
),
);
}