37
37
import bisq .core .payment .AssetAccount ;
38
38
import bisq .core .payment .PaymentAccount ;
39
39
import bisq .core .payment .payload .PaymentMethod ;
40
- import bisq .core .user .DontShowAgainLookup ;
41
40
import bisq .core .util .coin .CoinFormatter ;
42
41
import bisq .core .util .validation .InputValidator ;
43
42
68
67
import javafx .util .StringConverter ;
69
68
70
69
import java .util .Date ;
71
- import java .util .List ;
72
70
import java .util .concurrent .TimeUnit ;
73
71
74
72
import lombok .extern .slf4j .Slf4j ;
@@ -124,8 +122,8 @@ public TradeCurrency fromString(String s) {
124
122
paymentAccount .setSingleTradeCurrency (selectedCurrency );
125
123
updateFromInputs ();
126
124
127
- if (isArgentinePesos (selectedCurrency )) {
128
- maybeShowArgentinePesosBlueRatePopup ();
125
+ if (ArsBlueRatePopup . isTradeCurrencyArgentinePesos (selectedCurrency )) {
126
+ ArsBlueRatePopup . showMaybe ();
129
127
}
130
128
});
131
129
}
@@ -317,8 +315,8 @@ void fillUpFlowPaneWithCurrencies(boolean isEditable, FlowPane flowPane,
317
315
if (checkBox .isSelected ()) {
318
316
paymentAccount .addCurrency (e );
319
317
320
- if (isArgentinePesos (e )) {
321
- maybeShowArgentinePesosBlueRatePopup ();
318
+ if (ArsBlueRatePopup . isTradeCurrencyArgentinePesos (e )) {
319
+ ArsBlueRatePopup . showMaybe ();
322
320
}
323
321
324
322
} else {
@@ -329,8 +327,8 @@ void fillUpFlowPaneWithCurrencies(boolean isEditable, FlowPane flowPane,
329
327
});
330
328
flowPane .getChildren ().add (checkBox );
331
329
332
- if (isCurrencySelected && isArgentinePesos (e )) {
333
- maybeShowArgentinePesosBlueRatePopup ();
330
+ if (isCurrencySelected && ArsBlueRatePopup . isTradeCurrencyArgentinePesos (e )) {
331
+ ArsBlueRatePopup . showMaybe ();
334
332
}
335
333
}
336
334
@@ -372,22 +370,4 @@ void removeAcceptedCountry(String countryCode) {
372
370
373
371
void addAcceptedCountry (String countryCode ) {
374
372
}
375
-
376
- public static boolean isArgentinePesos (TradeCurrency tradeCurrency ) {
377
- FiatCurrency arsCurrency = new FiatCurrency ("ARS" );
378
- return tradeCurrency .equals (arsCurrency );
379
- }
380
-
381
- public static void maybeShowArgentinePesosBlueRatePopup () {
382
- String key = "arsBlueMarketNotificationPopup" ;
383
- if (DontShowAgainLookup .showAgain (key )) {
384
- new Popup ()
385
- .headLine (Res .get ("popup.arsBlueMarket.title" ))
386
- .information (Res .get ("popup.arsBlueMarket.info" ))
387
- .actionButtonText (Res .get ("shared.iUnderstand" ))
388
- .hideCloseButton ()
389
- .dontShowAgainId (key )
390
- .show ();
391
- }
392
- }
393
373
}
0 commit comments