mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-01-10 20:54:33 +00:00
prevent double loading of data
This commit is contained in:
parent
e81521e374
commit
89f806f394
1 changed files with 13 additions and 13 deletions
|
@ -13,7 +13,6 @@ import 'package:stackwallet/utilities/amount/amount.dart';
|
||||||
import 'package:stackwallet/utilities/assets.dart';
|
import 'package:stackwallet/utilities/assets.dart';
|
||||||
import 'package:stackwallet/utilities/enums/coin_enum.dart';
|
import 'package:stackwallet/utilities/enums/coin_enum.dart';
|
||||||
import 'package:stackwallet/utilities/logger.dart';
|
import 'package:stackwallet/utilities/logger.dart';
|
||||||
import 'package:stackwallet/utilities/show_loading.dart';
|
|
||||||
import 'package:stackwallet/utilities/text_styles.dart';
|
import 'package:stackwallet/utilities/text_styles.dart';
|
||||||
import 'package:stackwallet/utilities/theme/stack_colors.dart';
|
import 'package:stackwallet/utilities/theme/stack_colors.dart';
|
||||||
import 'package:stackwallet/utilities/util.dart';
|
import 'package:stackwallet/utilities/util.dart';
|
||||||
|
@ -76,17 +75,18 @@ class _ExchangeProviderOptionState
|
||||||
child: GestureDetector(
|
child: GestureDetector(
|
||||||
onTap: () {
|
onTap: () {
|
||||||
if (!selected) {
|
if (!selected) {
|
||||||
showLoading(
|
// showLoading(
|
||||||
whileFuture: ref.read(exchangeFormStateProvider).updateExchange(
|
// whileFuture:
|
||||||
exchange: widget.exchange,
|
ref.read(exchangeFormStateProvider).updateExchange(
|
||||||
shouldUpdateData: true,
|
exchange: widget.exchange,
|
||||||
shouldNotifyListeners: true,
|
shouldUpdateData: true,
|
||||||
providerName: widget.exchangeProvider,
|
shouldNotifyListeners: true,
|
||||||
),
|
providerName: widget.exchangeProvider,
|
||||||
context: context,
|
// ),
|
||||||
message: "Updating rates",
|
// context: context,
|
||||||
isDesktop: isDesktop,
|
// message: "Updating rates",
|
||||||
);
|
// isDesktop: isDesktop,
|
||||||
|
);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
child: Container(
|
child: Container(
|
||||||
|
@ -113,7 +113,7 @@ class _ExchangeProviderOptionState
|
||||||
if (!selected) {
|
if (!selected) {
|
||||||
ref.read(exchangeFormStateProvider).updateExchange(
|
ref.read(exchangeFormStateProvider).updateExchange(
|
||||||
exchange: widget.exchange,
|
exchange: widget.exchange,
|
||||||
shouldUpdateData: true,
|
shouldUpdateData: false,
|
||||||
shouldNotifyListeners: true,
|
shouldNotifyListeners: true,
|
||||||
providerName: widget.exchangeProvider,
|
providerName: widget.exchangeProvider,
|
||||||
);
|
);
|
||||||
|
|
Loading…
Reference in a new issue