fix wallet settings update bugs

This commit is contained in:
Craig Raw 2020-08-17 17:25:33 +02:00
parent 304bdd5c48
commit 75bf63d936
2 changed files with 4 additions and 3 deletions

View file

@ -62,7 +62,7 @@ public class UtxosChart extends BarChart<String, Number> {
}
if(utxoSeries.getData().size() > utxoDataList.size()) {
utxoSeries.getData().remove(utxoDataList.size() - 1, utxoSeries.getData().size());
utxoSeries.getData().remove(Math.max(0, utxoDataList.size() - 1), utxoSeries.getData().size());
}
if(selectedEntries != null) {

View file

@ -14,7 +14,6 @@ import javafx.collections.ListChangeListener;
import javafx.fxml.FXML;
import javafx.fxml.Initializable;
import javafx.scene.control.TreeItem;
import javafx.scene.input.MouseEvent;
import java.net.URL;
import java.util.ResourceBundle;
@ -47,8 +46,10 @@ public class TransactionsController extends WalletFormController implements Init
transactionsTable.initialize(walletTransactionsEntry);
balance.valueProperty().addListener((observable, oldValue, newValue) -> {
setFiatBalance(AppController.getFiatCurrencyExchangeRate(), newValue.longValue());
});
balance.setValue(walletTransactionsEntry.getBalance());
setFiatBalance(AppController.getFiatCurrencyExchangeRate(), walletTransactionsEntry.getBalance());
mempoolBalance.setValue(walletTransactionsEntry.getMempoolBalance());
balanceChart.initialize(walletTransactionsEntry);