mirror of
https://github.com/haveno-dex/haveno.git
synced 2025-06-26 07:40:35 -04:00
show extra info popup on take f2f offer
This commit is contained in:
parent
dc7a8e4201
commit
0d2c1fe8fd
1 changed files with 19 additions and 1 deletions
|
@ -162,7 +162,7 @@ public class TakeOfferView extends ActivatableViewAndModel<AnchorPane, TakeOffer
|
||||||
private final HashMap<String, Boolean> paymentAccountWarningDisplayed = new HashMap<>();
|
private final HashMap<String, Boolean> paymentAccountWarningDisplayed = new HashMap<>();
|
||||||
private boolean offerDetailsWindowDisplayed, zelleWarningDisplayed, fasterPaymentsWarningDisplayed,
|
private boolean offerDetailsWindowDisplayed, zelleWarningDisplayed, fasterPaymentsWarningDisplayed,
|
||||||
takeOfferFromUnsignedAccountWarningDisplayed, payByMailWarningDisplayed, cashAtAtmWarningDisplayed,
|
takeOfferFromUnsignedAccountWarningDisplayed, payByMailWarningDisplayed, cashAtAtmWarningDisplayed,
|
||||||
australiaPayidWarningDisplayed, paypalWarningDisplayed, cashAppWarningDisplayed;
|
australiaPayidWarningDisplayed, paypalWarningDisplayed, cashAppWarningDisplayed, F2FWarningDisplayed;
|
||||||
private SimpleBooleanProperty errorPopupDisplayed;
|
private SimpleBooleanProperty errorPopupDisplayed;
|
||||||
private ChangeListener<Boolean> amountFocusedListener, getShowWalletFundedNotificationListener;
|
private ChangeListener<Boolean> amountFocusedListener, getShowWalletFundedNotificationListener;
|
||||||
|
|
||||||
|
@ -276,6 +276,7 @@ public class TakeOfferView extends ActivatableViewAndModel<AnchorPane, TakeOffer
|
||||||
maybeShowAustraliaPayidWarning(lastPaymentAccount, model.dataModel.getOffer());
|
maybeShowAustraliaPayidWarning(lastPaymentAccount, model.dataModel.getOffer());
|
||||||
maybeShowPayPalWarning(lastPaymentAccount, model.dataModel.getOffer());
|
maybeShowPayPalWarning(lastPaymentAccount, model.dataModel.getOffer());
|
||||||
maybeShowCashAppWarning(lastPaymentAccount, model.dataModel.getOffer());
|
maybeShowCashAppWarning(lastPaymentAccount, model.dataModel.getOffer());
|
||||||
|
maybeShowF2FWarning(lastPaymentAccount, model.dataModel.getOffer());
|
||||||
|
|
||||||
if (!model.isRange()) {
|
if (!model.isRange()) {
|
||||||
nextButton.setVisible(false);
|
nextButton.setVisible(false);
|
||||||
|
@ -1235,6 +1236,23 @@ public class TakeOfferView extends ActivatableViewAndModel<AnchorPane, TakeOffer
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void maybeShowF2FWarning(PaymentAccount paymentAccount, Offer offer) {
|
||||||
|
if (paymentAccount.getPaymentMethod().getId().equals(PaymentMethod.F2F_ID) &&
|
||||||
|
!F2FWarningDisplayed && !offer.getExtraInfo().isEmpty()) {
|
||||||
|
F2FWarningDisplayed = true;
|
||||||
|
UserThread.runAfter(() -> {
|
||||||
|
new GenericMessageWindow()
|
||||||
|
.preamble(Res.get("payment.tradingRestrictions"))
|
||||||
|
.instruction(offer.getExtraInfo())
|
||||||
|
.actionButtonText(Res.get("shared.iConfirm"))
|
||||||
|
.closeButtonText(Res.get("shared.close"))
|
||||||
|
.width(Layout.INITIAL_WINDOW_WIDTH)
|
||||||
|
.onClose(() -> close(false))
|
||||||
|
.show();
|
||||||
|
}, 500, TimeUnit.MILLISECONDS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private Tuple2<Label, VBox> getTradeInputBox(HBox amountValueBox, String promptText) {
|
private Tuple2<Label, VBox> getTradeInputBox(HBox amountValueBox, String promptText) {
|
||||||
Label descriptionLabel = new AutoTooltipLabel(promptText);
|
Label descriptionLabel = new AutoTooltipLabel(promptText);
|
||||||
descriptionLabel.setId("input-description-label");
|
descriptionLabel.setId("input-description-label");
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue