From f8a22d53056154da4fa6df7fe462686a661a7962 Mon Sep 17 00:00:00 2001 From: Yana Stamcheva Date: Mon, 23 Oct 2006 12:41:52 +0000 Subject: [PATCH] do not open the popup if the user input doesn't match any of the items in the combo box --- .../impl/gui/customcontrols/SmartComboBox.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/net/java/sip/communicator/impl/gui/customcontrols/SmartComboBox.java b/src/net/java/sip/communicator/impl/gui/customcontrols/SmartComboBox.java index eac7f63f2..7a1d1cf88 100644 --- a/src/net/java/sip/communicator/impl/gui/customcontrols/SmartComboBox.java +++ b/src/net/java/sip/communicator/impl/gui/customcontrols/SmartComboBox.java @@ -211,9 +211,12 @@ protected void handleChange() } ((FilterableComboBoxModel) getModel()).setFilter(filter); - // A bit nasty but it seems to get the popup validated properly + setPopupVisible(false); - setPopupVisible(true); + + if(getModel().getSize() > 0) + setPopupVisible(true); + filtering = false; } }