mirror of
https://github.com/haveno-dex/haveno.git
synced 2024-10-01 01:35:48 -04:00
preserve withdraw fields when page reactivated while in progress
This commit is contained in:
parent
e18d281ca9
commit
caebd58303
@ -242,8 +242,12 @@ public class WithdrawalView extends ActivatableView<VBox, Void> {
|
|||||||
if (GUIUtil.isReadyForTxBroadcastOrShowPopup(xmrWalletService)) {
|
if (GUIUtil.isReadyForTxBroadcastOrShowPopup(xmrWalletService)) {
|
||||||
try {
|
try {
|
||||||
|
|
||||||
|
// collect tx fields to local variables
|
||||||
|
String withdrawToAddress = withdrawToTextField.getText();
|
||||||
|
boolean sendMax = this.sendMax;
|
||||||
|
BigInteger amount = this.amount;
|
||||||
|
|
||||||
// validate address
|
// validate address
|
||||||
final String withdrawToAddress = withdrawToTextField.getText();
|
|
||||||
if (!MoneroUtils.isValidAddress(withdrawToAddress, XmrWalletService.getMoneroNetworkType())) {
|
if (!MoneroUtils.isValidAddress(withdrawToAddress, XmrWalletService.getMoneroNetworkType())) {
|
||||||
throw new IllegalArgumentException(Res.get("validation.xmr.invalidAddress"));
|
throw new IllegalArgumentException(Res.get("validation.xmr.invalidAddress"));
|
||||||
}
|
}
|
||||||
@ -298,7 +302,7 @@ public class WithdrawalView extends ActivatableView<VBox, Void> {
|
|||||||
BigInteger receiverAmount = tx.getOutgoingTransfer().getDestinations().get(0).getAmount();
|
BigInteger receiverAmount = tx.getOutgoingTransfer().getDestinations().get(0).getAmount();
|
||||||
BigInteger fee = tx.getFee();
|
BigInteger fee = tx.getFee();
|
||||||
String messageText = Res.get("shared.sendFundsDetailsWithFee",
|
String messageText = Res.get("shared.sendFundsDetailsWithFee",
|
||||||
HavenoUtils.formatXmr(amount, true),
|
HavenoUtils.formatXmr(receiverAmount.add(fee), true),
|
||||||
withdrawToAddress,
|
withdrawToAddress,
|
||||||
HavenoUtils.formatXmr(fee, true),
|
HavenoUtils.formatXmr(fee, true),
|
||||||
HavenoUtils.formatXmr(receiverAmount, true));
|
HavenoUtils.formatXmr(receiverAmount, true));
|
||||||
|
Loading…
Reference in New Issue
Block a user