diff options
author | Henri Sara <hesara@vaadin.com> | 2015-11-05 11:16:55 +0200 |
---|---|---|
committer | Henri Sara <hesara@vaadin.com> | 2016-08-08 07:18:42 +0000 |
commit | 9428b12cb47cca814adc2d68b6363ef7082dee1d (patch) | |
tree | 1164ae594a4ad66370c1b518c7b3eac18ebd415e /server | |
parent | 0e1a271cc5e465a774f0d729fc9ad38b300757de (diff) | |
download | vaadin-framework-9428b12cb47cca814adc2d68b6363ef7082dee1d.tar.gz vaadin-framework-9428b12cb47cca814adc2d68b6363ef7082dee1d.zip |
Create ComboBoxServerRpc stub (#19229)
Create an empty client to server RPC implementation for ComboBox.
Change-Id: I1ccce4875682b8ba2541acdc42d361edb30ca458
Diffstat (limited to 'server')
-rw-r--r-- | server/src/main/java/com/vaadin/ui/ComboBox.java | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/server/src/main/java/com/vaadin/ui/ComboBox.java b/server/src/main/java/com/vaadin/ui/ComboBox.java index a6a562f2d2..d448f23ac7 100644 --- a/server/src/main/java/com/vaadin/ui/ComboBox.java +++ b/server/src/main/java/com/vaadin/ui/ComboBox.java @@ -34,6 +34,7 @@ import com.vaadin.event.FieldEvents.FocusListener; import com.vaadin.server.PaintException; import com.vaadin.server.PaintTarget; import com.vaadin.server.Resource; +import com.vaadin.shared.ui.combobox.ComboBoxServerRpc; import com.vaadin.shared.ui.combobox.ComboBoxState; import com.vaadin.shared.ui.combobox.FilteringMode; @@ -74,6 +75,10 @@ public class ComboBox extends AbstractSelect implements public String getStyle(ComboBox source, Object itemId); } + private ComboBoxServerRpc rpc = new ComboBoxServerRpc() { + + }; + /** * Holds value of property pageLength. 0 disables paging. */ @@ -130,28 +135,31 @@ public class ComboBox extends AbstractSelect implements private ItemStyleGenerator itemStyleGenerator = null; public ComboBox() { - initDefaults(); + init(); } public ComboBox(String caption, Collection<?> options) { super(caption, options); - initDefaults(); + init(); } public ComboBox(String caption, Container dataSource) { super(caption, dataSource); - initDefaults(); + init(); } public ComboBox(String caption) { super(caption); - initDefaults(); + init(); } /** - * Initialize the ComboBox with default settings + * Initialize the ComboBox with default settings and register client to + * server RPC implementation. */ - private void initDefaults() { + private void init() { + registerRpc(rpc); + setNewItemsAllowed(false); setImmediate(true); } |