mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-11-17 09:47:35 +00:00
[skip ci] fix fiat settings display
This commit is contained in:
parent
37ca795756
commit
a1dd22232b
2 changed files with 6 additions and 1 deletions
|
@ -34,7 +34,8 @@ class DisplaySettingsPage extends BasePage {
|
|||
onValueChange: (_, bool value) {
|
||||
_displaySettingsViewModel.setShouldDisplayBalance(value);
|
||||
}),
|
||||
if (!isHaven)
|
||||
//if (!isHaven) it does not work correctly
|
||||
if(!_displaySettingsViewModel.disabledFiatApiMode)
|
||||
SettingsPickerCell<FiatCurrency>(
|
||||
title: S.current.settings_currency,
|
||||
searchHintText: S.current.search_currency,
|
||||
|
|
|
@ -3,6 +3,7 @@ import 'package:cake_wallet/entities/fiat_currency.dart';
|
|||
import 'package:cake_wallet/store/settings_store.dart';
|
||||
import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
import 'package:cake_wallet/entities/fiat_api_mode.dart';
|
||||
|
||||
part 'display_settings_view_model.g.dart';
|
||||
|
||||
|
@ -30,6 +31,9 @@ abstract class DisplaySettingsViewModelBase with Store {
|
|||
@computed
|
||||
ThemeBase get theme => _settingsStore.currentTheme;
|
||||
|
||||
@computed
|
||||
bool get disabledFiatApiMode => _settingsStore.fiatApiMode == FiatApiMode.disabled;
|
||||
|
||||
@action
|
||||
void setBalanceDisplayMode(BalanceDisplayMode value) => _settingsStore.balanceDisplayMode = value;
|
||||
|
||||
|
|
Loading…
Reference in a new issue