]> source.dussan.org Git - vaadin-framework.git/commitdiff
Minor ComboBox client side cleanup (#19929)
authorHenri Sara <hesara@vaadin.com>
Thu, 12 Nov 2015 10:46:11 +0000 (12:46 +0200)
committerArtur Signell <artur@vaadin.com>
Mon, 8 Aug 2016 11:36:39 +0000 (11:36 +0000)
Remove unused references to immediate flags.

Change-Id: I4dfeccb9cb5c282c1b3a51bc5ff14a6fd62d3b1b

client/src/main/java/com/vaadin/client/ui/VFilterSelect.java
client/src/main/java/com/vaadin/client/ui/combobox/ComboBoxConnector.java

index af8d9f782af59b6e1b9197d97ae2c303c26915f1..96859b99b46e23414ec97c7f9e06132176a3db06 100644 (file)
@@ -80,7 +80,6 @@ import com.vaadin.client.ui.combobox.ComboBoxConnector;
 import com.vaadin.client.ui.menubar.MenuBar;
 import com.vaadin.client.ui.menubar.MenuItem;
 import com.vaadin.shared.AbstractComponentState;
-import com.vaadin.shared.EventId;
 import com.vaadin.shared.ui.ComponentStateUtil;
 import com.vaadin.shared.ui.combobox.FilteringMode;
 import com.vaadin.shared.util.SharedUtil;
@@ -1862,22 +1861,7 @@ public class VFilterSelect extends Composite implements Field, KeyDownHandler,
      *            The filter to apply to the components
      */
     public void filterOptions(int page, String filter) {
-        filterOptions(page, filter, true);
-    }
-
-    /**
-     * Filters the options at certain page using the given filter
-     * 
-     * @param page
-     *            The page to filter
-     * @param filter
-     *            The filter to apply to the options
-     * @param immediate
-     *            Whether to send the options request immediately
-     */
-    private void filterOptions(int page, String filter, boolean immediate) {
-        debug("VFS: filterOptions(" + page + ", " + filter + ", " + immediate
-                + ")");
+        debug("VFS: filterOptions(" + page + ", " + filter + ")");
 
         if (filter.equals(lastFilter) && currentPage == page) {
             if (!suggestionPopup.isAttached()) {
@@ -2467,12 +2451,7 @@ public class VFilterSelect extends Composite implements Field, KeyDownHandler,
             // ask suggestionPopup if it was just closed, we are using GWT
             // Popup's auto close feature
             if (!suggestionPopup.isJustClosed()) {
-                // If a focus event is not going to be sent, send the options
-                // request immediately; otherwise queue in the same burst as the
-                // focus event. Fixes #8321.
-                boolean immediate = focused
-                        || !connector.hasEventListener(EventId.FOCUS);
-                filterOptions(-1, "", immediate);
+                filterOptions(-1, "");
                 dataReceivedHandler.popupOpenerClicked();
                 lastFilter = "";
             }
index f0c71d76a21ca0e33226f73848d742b23d0d1194..c0d96fa32afffb896ab6e9f069ccdcfca3d6f604 100644 (file)
@@ -47,8 +47,6 @@ public class ComboBoxConnector extends AbstractFieldConnector implements
     protected FocusAndBlurServerRpc focusAndBlurRpc = RpcProxy.create(
             FocusAndBlurServerRpc.class, this);
 
-    private boolean immediate;
-
     @Override
     protected void init() {
         super.init();
@@ -64,8 +62,6 @@ public class ComboBoxConnector extends AbstractFieldConnector implements
         getWidget().readonly = isReadOnly();
         getWidget().updateReadOnly();
 
-        immediate = getState().immediate;
-
         getWidget().setTextInputEnabled(getState().textInputAllowed);
 
         if (getState().inputPrompt != null) {