mirror of
https://github.com/haveno-dex/haveno.git
synced 2024-12-24 06:49:31 -05:00
allow withraw without p2p connection
This commit is contained in:
parent
e450db1ec5
commit
5b50a553b4
@ -165,7 +165,7 @@ public class WithdrawalView extends ActivatableView<VBox, Void> {
|
|||||||
///////////////////////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
private void onWithdraw() {
|
private void onWithdraw() {
|
||||||
if (GUIUtil.isReadyForTxBroadcastOrShowPopup(p2PService, xmrWalletService.getConnectionsService())) {
|
if (GUIUtil.isReadyForTxBroadcastOrShowPopup(xmrWalletService.getConnectionsService())) {
|
||||||
try {
|
try {
|
||||||
|
|
||||||
// get withdraw address
|
// get withdraw address
|
||||||
|
@ -548,7 +548,7 @@ public class PendingTradesDataModel extends ActivatableDataModel {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public boolean isReadyForTxBroadcast() {
|
public boolean isReadyForTxBroadcast() {
|
||||||
return GUIUtil.isReadyForTxBroadcastOrShowPopup(p2PService, connectionService);
|
return GUIUtil.isBootstrappedOrShowPopup(p2PService) && GUIUtil.isReadyForTxBroadcastOrShowPopup(connectionService);
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isBootstrappedOrShowPopup() {
|
public boolean isBootstrappedOrShowPopup() {
|
||||||
|
@ -689,11 +689,7 @@ public class GUIUtil {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isReadyForTxBroadcastOrShowPopup(P2PService p2PService, CoreMoneroConnectionsService connectionService) {
|
public static boolean isReadyForTxBroadcastOrShowPopup(CoreMoneroConnectionsService connectionService) {
|
||||||
if (!GUIUtil.isBootstrappedOrShowPopup(p2PService)) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!connectionService.hasSufficientPeersForBroadcast()) {
|
if (!connectionService.hasSufficientPeersForBroadcast()) {
|
||||||
new Popup().information(Res.get("popup.warning.notSufficientConnectionsToBtcNetwork", connectionService.getMinBroadcastConnections())).show();
|
new Popup().information(Res.get("popup.warning.notSufficientConnectionsToBtcNetwork", connectionService.getMinBroadcastConnections())).show();
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
Reference in New Issue
Block a user