diff --git a/src/main/java/org/semux/gui/panel/SendPanel.java b/src/main/java/org/semux/gui/panel/SendPanel.java index 903f480f1..efa8f8966 100644 --- a/src/main/java/org/semux/gui/panel/SendPanel.java +++ b/src/main/java/org/semux/gui/panel/SendPanel.java @@ -336,17 +336,18 @@ protected void refresh() { } } - // add aliases to list of accounts - for (Map.Entry address : kernel.getWallet().getAddressAliases().entrySet()) { - // only add aliases not in wallet - if (kernel.getWallet().getAccount(address.getKey().getData()) == null) { - accountItems.add(new AccountItem(address.getValue(), address.getKey().getData())); + // 'to' contains all current accounts and address book, only update if user + // isn't interacting with it, and wallet is unlocked + if (!selectTo.isPopupVisible() && kernel.getWallet().isUnlocked()) { + + // add aliases to list of accounts + for (Map.Entry address : kernel.getWallet().getAddressAliases().entrySet()) { + // only add aliases not in wallet + if (kernel.getWallet().getAccount(address.getKey().getData()) == null) { + accountItems.add(new AccountItem(address.getValue(), address.getKey().getData())); + } } - } - // 'to' contains all current accounts and address book, only update if user - // isn't interacting with it - if (!selectTo.isPopupVisible()) { Object toSelected = selectTo.getSelectedItem(); selectTo.removeAllItems();