]> source.dussan.org Git - vaadin-framework.git/commitdiff
Select (ComboBox / FilterSelect) properly emptied if nulled serverside. Fixes #1436
authorMarc Englund <marc.englund@itmill.com>
Fri, 29 Feb 2008 09:04:34 +0000 (09:04 +0000)
committerMarc Englund <marc.englund@itmill.com>
Fri, 29 Feb 2008 09:04:34 +0000 (09:04 +0000)
svn changeset:3948/svn branch:trunk

src/com/itmill/toolkit/terminal/gwt/client/ui/IFilterSelect.java

index 34ed706f350d3d6baee27f8cd7f4e835e01dfdbd..c36249537084ebd6a045f515b6d2ca1eec1e7394 100644 (file)
@@ -554,6 +554,13 @@ public class IFilterSelect extends Composite implements Paintable,
         if (clientSideFiltering) {
             allSuggestions = new ArrayList();
         }
+
+        if (uidl.hasVariable("selected")
+                && uidl.getStringArrayVariable("selected").length == 0) {
+            // select nulled
+            tb.setText("");
+        }
+
         for (final Iterator i = options.getChildIterator(); i.hasNext();) {
             final UIDL optionUidl = (UIDL) i.next();
             final FilterSelectSuggestion suggestion = new FilterSelectSuggestion(