mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-01-24 11:15:58 +00:00
loading animation on sendCurrency
This commit is contained in:
parent
f0687df008
commit
7163d95cc4
1 changed files with 23 additions and 0 deletions
|
@ -116,6 +116,29 @@ class _ExchangeFormState extends ConsumerState<ExchangeForm> {
|
||||||
fromTicker: fromTicker,
|
fromTicker: fromTicker,
|
||||||
onSelected: (from) =>
|
onSelected: (from) =>
|
||||||
ref.read(exchangeFormStateProvider).updateFrom(from, true));
|
ref.read(exchangeFormStateProvider).updateFrom(from, true));
|
||||||
|
|
||||||
|
unawaited(
|
||||||
|
showDialog<void>(
|
||||||
|
context: context,
|
||||||
|
barrierDismissible: false,
|
||||||
|
builder: (_) => WillPopScope(
|
||||||
|
onWillPop: () async => false,
|
||||||
|
child: Container(
|
||||||
|
color: Theme.of(context)
|
||||||
|
.extension<StackColors>()!
|
||||||
|
.overlay
|
||||||
|
.withOpacity(0.6),
|
||||||
|
child: const CustomLoadingOverlay(
|
||||||
|
message: "Updating exchange rate",
|
||||||
|
eventBus: null,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
|
||||||
|
await Future<void>.delayed(const Duration(milliseconds: 300));
|
||||||
|
Navigator.of(context).pop();
|
||||||
} else {
|
} else {
|
||||||
final toTicker = ref.read(exchangeFormStateProvider).toTicker ?? "";
|
final toTicker = ref.read(exchangeFormStateProvider).toTicker ?? "";
|
||||||
final fromTicker = ref.read(exchangeFormStateProvider).fromTicker ?? "";
|
final fromTicker = ref.read(exchangeFormStateProvider).fromTicker ?? "";
|
||||||
|
|
Loading…
Reference in a new issue