From bcbb5314143d92e778f59fcf5e7f3f965a0cc866 Mon Sep 17 00:00:00 2001 From: Craig Raw Date: Thu, 22 Jun 2023 09:10:52 +0200 Subject: [PATCH] fix ui button update when stopping mixing on terminal --- .../sparrowwallet/sparrow/terminal/wallet/UtxosDialog.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/sparrowwallet/sparrow/terminal/wallet/UtxosDialog.java b/src/main/java/com/sparrowwallet/sparrow/terminal/wallet/UtxosDialog.java index f4f067f7..42ac5e67 100644 --- a/src/main/java/com/sparrowwallet/sparrow/terminal/wallet/UtxosDialog.java +++ b/src/main/java/com/sparrowwallet/sparrow/terminal/wallet/UtxosDialog.java @@ -81,7 +81,12 @@ public class UtxosDialog extends WalletDialog { } } - startMix.setLabel(newValue ? "Stop Mixing" : "Start Mixing"); + Whirlpool whirlpool = AppServices.getWhirlpoolServices().getWhirlpool(getWalletForm().getWallet()); + if(newValue) { + startMix.setLabel("Stop Mixing"); + } else if(whirlpool == null || !whirlpool.stoppingProperty().get()) { + startMix.setLabel("Start Mixing"); + } }; public UtxosDialog(WalletForm walletForm) {