color transaction values which deduct from wallet balance in red

This commit is contained in:
Craig Raw
2021-04-12 09:16:49 +02:00
parent 685fef6b76
commit 31fb527218
4 changed files with 17 additions and 0 deletions
@@ -66,6 +66,10 @@ class CoinCell extends TreeTableCell<Entry, Number> {
} else {
setGraphic(null);
}
if(amount.longValue() < 0) {
getStyleClass().add("negative-amount");
}
} else if(entry instanceof UtxoEntry) {
setGraphic(null);
} else if(entry instanceof HashIndexEntry) {
@@ -416,6 +416,7 @@ public class EntryCell extends TreeTableCell<Entry, Entry> {
cell.getStyleClass().remove("address-cell");
cell.getStyleClass().remove("hashindex-row");
cell.getStyleClass().remove("confirming");
cell.getStyleClass().remove("negative-amount");
cell.getStyleClass().remove("spent");
cell.getStyleClass().remove("unspendable");