Navigation between screens without previous states showing.

This commit is contained in:
Ivan Murashov
2018-03-09 08:30:07 +03:00
parent 58e58671de
commit ff72bd5403
5 changed files with 53 additions and 28 deletions

View File

@@ -39,10 +39,17 @@ class PurchaseScreenState<T> extends BaseState<PurchaseScreen> {
}
@override
Widget build(BuildContext ctx) {
void initState() {
setState(() {
requestAsyncData(user);
});
super.initState();
}
@override
Widget build(BuildContext ctx) {
return getMainWidget();
}
@@ -172,7 +179,7 @@ class PurchaseScreenState<T> extends BaseState<PurchaseScreen> {
child: new FlatButton(
child: new Text(title, style: new TextStyle(color: textColor)),
// FIXME: onPressed: () => startScanner(context, app, helper)),
onPressed: () => print('startScanner')),
onPressed: () => Navigator.of(context).pop(true)),
decoration: new BoxDecoration(
border: new Border.all(
color: Resources.getButtonColor(app), width: 1.0),