mirror of
https://github.com/bisq-network/bisq.git
synced 2025-01-19 05:44:05 +01:00
Merge pull request #6213 from jmacxx/check_trade_init_app_close
Improve wording & appearance of trade shutdown dialog.
This commit is contained in:
commit
0ced87cd22
@ -28,6 +28,8 @@ shared.readMore=Read more
|
||||
shared.openHelp=Open Help
|
||||
shared.warning=Warning
|
||||
shared.close=Close
|
||||
shared.closeAnywayDanger=Shut down anyway (DANGER!)
|
||||
shared.okWait=Ok I'll wait
|
||||
shared.cancel=Cancel
|
||||
shared.ok=OK
|
||||
shared.yes=Yes
|
||||
@ -3080,10 +3082,8 @@ popup.info.shutDownWithOpenOffers=Bisq is being shut down, but there are open of
|
||||
they will be re-published to the P2P network the next time you start Bisq.\n\n\
|
||||
To keep your offers online, keep Bisq running and make sure this computer remains online too \
|
||||
(i.e., make sure it doesn't go into standby mode...monitor standby is not a problem).
|
||||
popup.info.shutDownWithTradeInit=Bisq is being shut down, but there are trades still being initialized. \n\n\
|
||||
Specific trade affected: {0}\n\n\
|
||||
If a trade is still in process of being initialized, shutting down can result in the trade missing some important state.\n\n\
|
||||
Do not close Bisq if this trade has not had enough time to initialize correctly. One minute should be sufficient time.
|
||||
popup.info.shutDownWithTradeInit={0}\n\
|
||||
This trade has not finished initializing; shutting down now will probably make it corrupted. Please wait a minute and try again.
|
||||
popup.info.qubesOSSetupInfo=It appears you are running Bisq on Qubes OS. \n\n\
|
||||
Please make sure your Bisq qube is setup according to our Setup Guide at [HYPERLINK:https://bisq.wiki/Running_Bisq_on_Qubes].
|
||||
popup.info.firewallSetupInfo=It appears this machine blocks incoming Tor connections. \
|
||||
|
@ -384,24 +384,19 @@ public class BisqApp extends Application implements UncaughtExceptionHandler {
|
||||
if (trade.getTradePhase().equals(Trade.Phase.TAKER_FEE_PUBLISHED) &&
|
||||
new Date(trade.getTakeOfferDate()).toInstant().isAfter(fiveMinutesAgo)) {
|
||||
String tradeDateString = DisplayUtils.formatDateTime(new Date(trade.getTakeOfferDate()));
|
||||
tradeIdsWithOperationsPending += System.lineSeparator() +
|
||||
Res.get("shared.tradeId") + ": " + trade.getShortId() + " " +
|
||||
Res.get("shared.dateTime") + ": " + tradeDateString;
|
||||
tradeIdsWithOperationsPending += Res.get("shared.tradeId") + ": " + trade.getShortId() + " " +
|
||||
Res.get("shared.dateTime") + ": " + tradeDateString + System.lineSeparator();
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (tradeIdsWithOperationsPending.length() > 0) {
|
||||
// We show a popup to inform user that some trades are still being initialised.
|
||||
String key = "showInitTradeWarnPopupAtShutDown";
|
||||
if (injector.getInstance(Preferences.class).showAgain(key) && !DevEnv.isDevMode()) {
|
||||
new Popup().information(Res.get("popup.info.shutDownWithTradeInit", tradeIdsWithOperationsPending))
|
||||
.dontShowAgainId(key)
|
||||
.useShutDownButton()
|
||||
.onAction(() -> asyncStatus.complete(true))
|
||||
.closeButtonText(Res.get("shared.cancel"))
|
||||
.onClose(() -> asyncStatus.complete(false))
|
||||
.show();
|
||||
}
|
||||
new Popup().warning(Res.get("popup.info.shutDownWithTradeInit", tradeIdsWithOperationsPending))
|
||||
.actionButtonText(Res.get("shared.okWait"))
|
||||
.onAction(() -> asyncStatus.complete(false))
|
||||
.closeButtonText(Res.get("shared.closeAnywayDanger"))
|
||||
.onClose(() -> asyncStatus.complete(true))
|
||||
.show();
|
||||
} else {
|
||||
asyncStatus.complete(true);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user