mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-03-25 08:38:45 +00:00
eth token refresh fix
This commit is contained in:
parent
5de3723752
commit
1cd7289fe2
1 changed files with 1 additions and 21 deletions
|
@ -62,27 +62,7 @@ class _RefreshButtonState extends ConsumerState<WalletRefreshButton> {
|
||||||
_syncStatusSubscription =
|
_syncStatusSubscription =
|
||||||
eventBus.on<WalletSyncStatusChangedEvent>().listen(
|
eventBus.on<WalletSyncStatusChangedEvent>().listen(
|
||||||
(event) async {
|
(event) async {
|
||||||
if (event.walletId == widget.walletId &&
|
if (event.walletId == widget.walletId) {
|
||||||
widget.tokenContractAddress == null) {
|
|
||||||
switch (event.newStatus) {
|
|
||||||
case WalletSyncStatus.unableToSync:
|
|
||||||
if (_spinController.hasLoadedAnimation) {
|
|
||||||
_spinController.stop?.call();
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case WalletSyncStatus.synced:
|
|
||||||
if (_spinController.hasLoadedAnimation) {
|
|
||||||
_spinController.stop?.call();
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case WalletSyncStatus.syncing:
|
|
||||||
if (_spinController.hasLoadedAnimation) {
|
|
||||||
_spinController.repeat?.call();
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
} else if (widget.tokenContractAddress != null &&
|
|
||||||
event.walletId == widget.walletId + widget.tokenContractAddress!) {
|
|
||||||
switch (event.newStatus) {
|
switch (event.newStatus) {
|
||||||
case WalletSyncStatus.unableToSync:
|
case WalletSyncStatus.unableToSync:
|
||||||
if (_spinController.hasLoadedAnimation) {
|
if (_spinController.hasLoadedAnimation) {
|
||||||
|
|
Loading…
Reference in a new issue