mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-11-17 01:37:40 +00:00
Fix Navigation issue where popping 2 routes at the same time (#584)
This commit is contained in:
parent
65dfb83a27
commit
e8b3a0648a
1 changed files with 10 additions and 9 deletions
|
@ -111,15 +111,16 @@ class AuthPageState extends State<AuthPage> {
|
|||
throw Exception('Key context is null. Should be not happened');
|
||||
}
|
||||
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) async {
|
||||
await _authBar?.dismiss();
|
||||
await _progressBar?.dismiss();
|
||||
|
||||
if (route != null) {
|
||||
Navigator.of(_key.currentContext!).pushReplacementNamed(route);
|
||||
} else {
|
||||
Navigator.of(_key.currentContext!).pop();
|
||||
}
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||
dismissFlushBar(_authBar);
|
||||
dismissFlushBar(_progressBar);
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||
if (route != null) {
|
||||
Navigator.of(_key.currentContext!).pushReplacementNamed(route);
|
||||
} else {
|
||||
Navigator.of(_key.currentContext!).pop();
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue