From d0a6646bcdb6f05591c1eb58a3766c7fbce38690 Mon Sep 17 00:00:00 2001 From: woodser Date: Wed, 19 Apr 2023 08:04:12 -0400 Subject: [PATCH] Signed Offers view only appears for arbitrator --- .../desktop/main/support/SupportView.java | 21 ++++++++++--------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/desktop/src/main/java/haveno/desktop/main/support/SupportView.java b/desktop/src/main/java/haveno/desktop/main/support/SupportView.java index 3dd7864d..0487c804 100644 --- a/desktop/src/main/java/haveno/desktop/main/support/SupportView.java +++ b/desktop/src/main/java/haveno/desktop/main/support/SupportView.java @@ -163,10 +163,17 @@ public class SupportView extends ActivatableView { // In case a arbitrator has become inactive he still might get disputes from pending trades boolean hasDisputesAsArbitrator = arbitrationManager.getDisputesAsObservableList().stream() .anyMatch(d -> d.getAgentPubKeyRing().equals(myPubKeyRing)); - if (arbitratorTab == null && (isActiveArbitrator || hasDisputesAsArbitrator)) { - arbitratorTab = new Tab(); - arbitratorTab.setClosable(false); - root.getTabs().add(arbitratorTab); + if (isActiveArbitrator || hasDisputesAsArbitrator) { + if (arbitratorTab == null) { + arbitratorTab = new Tab(); + arbitratorTab.setClosable(false); + root.getTabs().add(arbitratorTab); + } + if (signedOfferTab == null) { + signedOfferTab = new Tab(); + signedOfferTab.setClosable(false); + root.getTabs().add(signedOfferTab); + } } } @@ -183,12 +190,6 @@ public class SupportView extends ActivatableView { } } - if (signedOfferTab == null) { - signedOfferTab = new Tab(); - signedOfferTab.setClosable(false); - root.getTabs().add(signedOfferTab); - } - boolean isActiveRefundAgent = refundAgentManager.getObservableMap().values().stream() .anyMatch(e -> e.getPubKeyRing() != null && e.getPubKeyRing().equals(myPubKeyRing)); if (refundAgentTab == null) {