mirror of
https://github.com/haveno-dex/haveno.git
synced 2025-06-25 07:10:48 -04:00
show MS addresses
This commit is contained in:
parent
2a5dc9d2af
commit
54c2b397ae
1 changed files with 7 additions and 21 deletions
|
@ -39,7 +39,6 @@ public class TransactionsListItem {
|
||||||
|
|
||||||
private final Tooltip tooltip;
|
private final Tooltip tooltip;
|
||||||
private String addressString;
|
private String addressString;
|
||||||
private boolean notAnAddress;
|
|
||||||
private AddressConfidenceListener confidenceListener;
|
private AddressConfidenceListener confidenceListener;
|
||||||
|
|
||||||
public TransactionsListItem(Transaction transaction, WalletService walletService, BSFormatter formatter) {
|
public TransactionsListItem(Transaction transaction, WalletService walletService, BSFormatter formatter) {
|
||||||
|
@ -55,14 +54,10 @@ public class TransactionsListItem {
|
||||||
if (!transactionOutput.isMine(walletService.getWallet())) {
|
if (!transactionOutput.isMine(walletService.getWallet())) {
|
||||||
type.set("Sent to");
|
type.set("Sent to");
|
||||||
|
|
||||||
if (transactionOutput.getScriptPubKey().isSentToAddress() ||
|
if (transactionOutput.getScriptPubKey().isSentToAddress()
|
||||||
transactionOutput.getScriptPubKey().isPayToScriptHash()) {
|
|| transactionOutput.getScriptPubKey().isPayToScriptHash()) {
|
||||||
address =
|
address = transactionOutput.getScriptPubKey().getToAddress(walletService.getWallet().getParams());
|
||||||
transactionOutput.getScriptPubKey().getToAddress(walletService.getWallet().getParams());
|
|
||||||
addressString = address.toString();
|
addressString = address.toString();
|
||||||
} else {
|
|
||||||
addressString = "No sent to address script used.";
|
|
||||||
notAnAddress = true;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -74,12 +69,8 @@ public class TransactionsListItem {
|
||||||
if (transactionOutput.isMine(walletService.getWallet())) {
|
if (transactionOutput.isMine(walletService.getWallet())) {
|
||||||
if (transactionOutput.getScriptPubKey().isSentToAddress() ||
|
if (transactionOutput.getScriptPubKey().isSentToAddress() ||
|
||||||
transactionOutput.getScriptPubKey().isPayToScriptHash()) {
|
transactionOutput.getScriptPubKey().isPayToScriptHash()) {
|
||||||
address =
|
address = transactionOutput.getScriptPubKey().getToAddress(walletService.getWallet().getParams());
|
||||||
transactionOutput.getScriptPubKey().getToAddress(walletService.getWallet().getParams());
|
|
||||||
addressString = address.toString();
|
addressString = address.toString();
|
||||||
} else {
|
|
||||||
addressString = "No sent to address script used.";
|
|
||||||
notAnAddress = true;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -91,12 +82,8 @@ public class TransactionsListItem {
|
||||||
outgoing = true;
|
outgoing = true;
|
||||||
if (transactionOutput.getScriptPubKey().isSentToAddress() || transactionOutput.getScriptPubKey()
|
if (transactionOutput.getScriptPubKey().isSentToAddress() || transactionOutput.getScriptPubKey()
|
||||||
.isPayToScriptHash()) {
|
.isPayToScriptHash()) {
|
||||||
address = transactionOutput.getScriptPubKey().getToAddress(walletService.getWallet().getParams
|
address = transactionOutput.getScriptPubKey().getToAddress(walletService.getWallet().getParams());
|
||||||
());
|
|
||||||
addressString = address.toString();
|
addressString = address.toString();
|
||||||
} else {
|
|
||||||
addressString = "No sent to address script used.";
|
|
||||||
notAnAddress = true;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -105,8 +92,7 @@ public class TransactionsListItem {
|
||||||
type.set("Sent to");
|
type.set("Sent to");
|
||||||
} else {
|
} else {
|
||||||
type.set("Internal (TX Fee)");
|
type.set("Internal (TX Fee)");
|
||||||
addressString = "Internal swap between addresses.";
|
//addressString = "Internal swap between addresses.";
|
||||||
notAnAddress = true;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -190,7 +176,7 @@ public class TransactionsListItem {
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isNotAnAddress() {
|
public boolean isNotAnAddress() {
|
||||||
return notAnAddress;
|
return addressString == null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue