mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2025-01-30 14:36:06 +00:00
minor fix
This commit is contained in:
parent
8e6901118a
commit
381830d5af
2 changed files with 4 additions and 3 deletions
|
@ -364,7 +364,7 @@ class CryptoBalanceWidget extends StatelessWidget {
|
||||||
),
|
),
|
||||||
Observer(
|
Observer(
|
||||||
builder: (_) => StandardSwitch(
|
builder: (_) => StandardSwitch(
|
||||||
value: dashboardViewModel.mwebEnabled,
|
value: dashboardViewModel.mwebScanningActive,
|
||||||
onTaped: () => _toggleMweb(context),
|
onTaped: () => _toggleMweb(context),
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
|
@ -423,7 +423,7 @@ class CryptoBalanceWidget extends StatelessWidget {
|
||||||
}
|
}
|
||||||
|
|
||||||
Future<void> _toggleMweb(BuildContext context) async {
|
Future<void> _toggleMweb(BuildContext context) async {
|
||||||
return dashboardViewModel.setMwebEnabled(!dashboardViewModel.mwebEnabled);
|
return dashboardViewModel.setMwebScanningActive(!dashboardViewModel.mwebScanningActive);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -372,11 +372,12 @@ abstract class DashboardViewModelBase with Store {
|
||||||
bool mwebScanningActive = false;
|
bool mwebScanningActive = false;
|
||||||
|
|
||||||
@action
|
@action
|
||||||
void setMwebEnabled(bool active) {
|
void setMwebScanningActive(bool active) {
|
||||||
if (!hasMweb) {
|
if (!hasMweb) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
mwebScanningActive = active;
|
||||||
bitcoin!.setMwebEnabled(wallet, active);
|
bitcoin!.setMwebEnabled(wallet, active);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue