mirror of
https://github.com/haveno-dex/haveno.git
synced 2025-08-02 03:36:24 -04:00
Add popups
This commit is contained in:
parent
8bf207b656
commit
cb8761b74e
32 changed files with 178 additions and 117 deletions
|
@ -21,7 +21,9 @@ public class PopupId {
|
|||
|
||||
// We don't use an enum because it would break updates if we add a new item in a new version
|
||||
|
||||
public static String SEC_DEPOSIT = "SEC_DEPOSIT";
|
||||
public static String TRADE_WALLET = "TRADE_WALLET";
|
||||
public static String TRADE_WALLET = "tradeWallet";
|
||||
public static String SEND_PAYMENT_INFO = "sendPaymentInfo";
|
||||
public static String PAYMENT_SENT = "paymentSent";
|
||||
public static String PAYMENT_RECEIVED = "paymentReceived";
|
||||
|
||||
}
|
||||
|
|
|
@ -143,8 +143,10 @@ public class Preferences implements Serializable {
|
|||
showTakeOfferConfirmation = true;
|
||||
|
||||
showAgainMap = new HashMap<>();
|
||||
showAgainMap.put(PopupId.SEC_DEPOSIT, true);
|
||||
showAgainMap.put(PopupId.TRADE_WALLET, true);
|
||||
showAgainMap.put(PopupId.SEND_PAYMENT_INFO, true);
|
||||
showAgainMap.put(PopupId.PAYMENT_SENT, true);
|
||||
showAgainMap.put(PopupId.PAYMENT_RECEIVED, true);
|
||||
|
||||
storage.queueUpForSave();
|
||||
}
|
||||
|
@ -345,6 +347,10 @@ public class Preferences implements Serializable {
|
|||
return showAgainMap;
|
||||
}
|
||||
|
||||
public boolean showAgain(String key) {
|
||||
return getShowAgainMap().containsKey(key) && getShowAgainMap().get(key);
|
||||
}
|
||||
|
||||
public boolean getTacAccepted() {
|
||||
return tacAccepted;
|
||||
}
|
||||
|
|
|
@ -269,7 +269,11 @@ public class User implements Serializable {
|
|||
}*/
|
||||
|
||||
public Arbitrator getAcceptedArbitratorByAddress(Address address) {
|
||||
return acceptedArbitrators.stream().filter(e -> e.getArbitratorAddress().equals(address)).findFirst().get();
|
||||
Optional<Arbitrator> arbitratorOptional = acceptedArbitrators.stream().filter(e -> e.getArbitratorAddress().equals(address)).findFirst();
|
||||
if (arbitratorOptional.isPresent())
|
||||
return arbitratorOptional.get();
|
||||
else
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue