mirror of
https://github.com/haveno-dex/haveno.git
synced 2025-07-28 17:34:11 -04:00
Improve popups
This commit is contained in:
parent
cb8761b74e
commit
6f523e02dd
14 changed files with 71 additions and 38 deletions
|
@ -472,9 +472,10 @@ public class TradeWalletService {
|
|||
// Check if OP_RETURN output with contract hash matches the one from the offerer
|
||||
TransactionOutput contractHashOutput = new TransactionOutput(params, offerersDepositTx, Coin.ZERO,
|
||||
ScriptBuilder.createOpReturnScript(contractHash).getProgram());
|
||||
|
||||
log.debug("contractHashOutput " + contractHashOutput);
|
||||
TransactionOutput offerersContractHashOutput = offerersDepositTx.getOutputs().get(1);
|
||||
if (!offerersContractHashOutput.equals(contractHashOutput))
|
||||
log.debug("offerersContractHashOutput " + offerersContractHashOutput);
|
||||
if (!offerersContractHashOutput.getScriptPubKey().equals(contractHashOutput.getScriptPubKey()))
|
||||
throw new TransactionVerificationException("Offerers transaction output for the contract hash is not matching takers version.");
|
||||
|
||||
// Add all outputs from offerersDepositTx to depositTx
|
||||
|
|
|
@ -41,6 +41,11 @@ public class SignAndPublishDepositTxAsBuyer extends TradeTask {
|
|||
try {
|
||||
runInterceptHook();
|
||||
|
||||
log.debug("getContractAsJson");
|
||||
log.debug("----------");
|
||||
log.debug(trade.getContractAsJson());
|
||||
log.debug("----------");
|
||||
|
||||
byte[] contractHash = Hash.getHash(trade.getContractAsJson());
|
||||
trade.setContractHash(contractHash);
|
||||
processModel.getTradeWalletService().takerSignsAndPublishesDepositTx(
|
||||
|
|
|
@ -44,6 +44,7 @@ public class SignAndPublishDepositTxAsSeller extends TradeTask {
|
|||
log.debug("----------");
|
||||
log.debug(trade.getContractAsJson());
|
||||
log.debug("----------");
|
||||
|
||||
byte[] contractHash = Hash.getHash(trade.getContractAsJson());
|
||||
trade.setContractHash(contractHash);
|
||||
processModel.getTradeWalletService().takerSignsAndPublishesDepositTx(
|
||||
|
|
|
@ -348,7 +348,13 @@ public class Preferences implements Serializable {
|
|||
}
|
||||
|
||||
public boolean showAgain(String key) {
|
||||
return getShowAgainMap().containsKey(key) && getShowAgainMap().get(key);
|
||||
// if we add new and those are not in our stored map we display by default the new popup
|
||||
if (!getShowAgainMap().containsKey(key)) {
|
||||
showAgainMap.put(key, true);
|
||||
storage.queueUpForSave();
|
||||
}
|
||||
|
||||
return showAgainMap.get(key);
|
||||
}
|
||||
|
||||
public boolean getTacAccepted() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue