mirror of
https://github.com/bisq-network/bisq.git
synced 2024-11-19 09:52:23 +01:00
Persist "show all" state in currency selector in trade charts view
This commit is contained in:
parent
ede420375f
commit
b5454b3b92
@ -129,7 +129,10 @@ class TradesChartsViewModel extends ActivatableViewModel {
|
|||||||
fillTradeCurrencies();
|
fillTradeCurrencies();
|
||||||
};
|
};
|
||||||
|
|
||||||
Optional<TradeCurrency> tradeCurrencyOptional = CurrencyUtil.getTradeCurrency(preferences.getTradeChartsScreenCurrencyCode());
|
String tradeChartsScreenCurrencyCode = preferences.getTradeChartsScreenCurrencyCode();
|
||||||
|
showAllTradeCurrenciesProperty.set(isShowAllEntry(tradeChartsScreenCurrencyCode));
|
||||||
|
|
||||||
|
Optional<TradeCurrency> tradeCurrencyOptional = CurrencyUtil.getTradeCurrency(tradeChartsScreenCurrencyCode);
|
||||||
if (tradeCurrencyOptional.isPresent())
|
if (tradeCurrencyOptional.isPresent())
|
||||||
selectedTradeCurrencyProperty.set(tradeCurrencyOptional.get());
|
selectedTradeCurrencyProperty.set(tradeCurrencyOptional.get());
|
||||||
else
|
else
|
||||||
@ -186,8 +189,8 @@ class TradesChartsViewModel extends ActivatableViewModel {
|
|||||||
showAllTradeCurrenciesProperty.set(showAllEntry);
|
showAllTradeCurrenciesProperty.set(showAllEntry);
|
||||||
if (!showAllEntry) {
|
if (!showAllEntry) {
|
||||||
selectedTradeCurrencyProperty.set(tradeCurrency);
|
selectedTradeCurrencyProperty.set(tradeCurrency);
|
||||||
preferences.setTradeChartsScreenCurrencyCode(code);
|
|
||||||
}
|
}
|
||||||
|
preferences.setTradeChartsScreenCurrencyCode(code);
|
||||||
|
|
||||||
updateChartData();
|
updateChartData();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user