vaadin7

Using Vaadin on NetBeans WITHOUT Maven

情到浓时终转凉″ 提交于 2019-12-02 08:15:53
问题 I'm starting with Vaadin and I'd like to know if it's possible work with this framework in NetBeans without using maven. The reason is the project using maven takes ages downloading dependencies and never reaches to run because of a timeout connection problem. I've downloaded the All-in-one file and tried following these README.txt file instructions: Copy all vaadin-* files except vaadin-client and vaadin-client-compiler to WEB-INF/lib in your project Copy lib/*.jar to WEB-INF/lib in your

VAADIN 7: What is the simplest way to refresh a Vaadin View in 5 minute intervals?

本秂侑毒 提交于 2019-12-02 06:16:46
I'm trying to implement an automatic refresh on a List of components in a Vaadin view. The list gets its contents from a database. I can refresh the list with a button, that is already implemented. However, I would like to know what is the simplest way to make it so, that this refresh event, that I already have, would automatically refresh in 5 minute (300 000 milliseconds) intervals? Here's what I tried and it keeps refreshing even after I exit the view so it doesn't really work. I'd like the refresh to happen in 5 minute intervals only while that certain view is being shown. UI myUI = UI

Want to have a layout which arrange in a tabular form

不问归期 提交于 2019-12-02 04:07:40
I am very new to Vaadin. My requirement is like in my page I need to have 4 input component per row. There would be 4 rows like this. I need a layout which will allow me to define number of columns and keep align it. There should not be any border like we have in table. Please suggest me any suitable layout and how can I customize that. Thanks You are probably looking for a GridLayout , it provides enough flexibility to size your grid 'cells', maintain consistency and set expand ratios for row and columns separately. The other option for you is to use a CustomComponent and in case you are

How to validate fields in vaadin made form

喜夏-厌秋 提交于 2019-12-02 01:32:16
问题 I am making a Java project with vaadin. Right now I have a user registration form looking like that: public class RegistrationComponent extends CustomComponent implements View { public static final String VIEW_NAME = "Registration"; public RegistrationComponent(){ Panel panel = new Panel("Registration Form"); panel.setSizeUndefined(); FormLayout content = new FormLayout(); CheckBox checkBox1, checkBox2, checkBox3; checkBox1 = new CheckBox("Check Box 1"); checkBox2 = new CheckBox("Check Box 2"

How to validate fields in vaadin made form

佐手、 提交于 2019-12-02 00:59:25
I am making a Java project with vaadin. Right now I have a user registration form looking like that: public class RegistrationComponent extends CustomComponent implements View { public static final String VIEW_NAME = "Registration"; public RegistrationComponent(){ Panel panel = new Panel("Registration Form"); panel.setSizeUndefined(); FormLayout content = new FormLayout(); CheckBox checkBox1, checkBox2, checkBox3; checkBox1 = new CheckBox("Check Box 1"); checkBox2 = new CheckBox("Check Box 2"); checkBox3 = new CheckBox("Check Box 3"); checkBox1.setRequired(true); checkBox2.setRequired(true);

In Vaadin 7, pass data/arguments to new UI instance of BrowserWindowOpener?

可紊 提交于 2019-12-01 21:31:34
问题 I am successfully opening new browser windows with BrowserWindowOpener. Question: How do I pass some information to the newly instantiated UI subclass? The syntax requires that I specify a class to be instantiated. How do I communicate with that future instance? BrowserWindowOpener bookOpener = new BrowserWindowOpener( BookUI.class ); For example, let's say my app opens a window listing word definitions for words starting with a particular letter of the alphabet (A-Z). How do I tell the newly

Vaadin 7 fire custom events between components

允我心安 提交于 2019-12-01 21:02:01
I want to create custom events and fire them in some part of the view such that some other part of the view is updated/removed/refreshed. I have tried by extending the Component.Event and Component.Listener but it doesn't work. I think that events and listeners mustbe limited to the same component instance. Can this be done with Vaadin 7? Basically I want to decouple my views and provide easy communication between components. I'm also using Spring with Vaadin. If you have better ideas beside the Observer pattern I would also appreciate it. Thank you vlad2005 What you need: 1. A component that

Both ENTER shortcut and TextArea in Vaadin

主宰稳场 提交于 2019-12-01 20:18:36
TextField f = new TextField(); Button b = new Button("Save"); b.setClickShortcut(KeyCode.ENTER); // For quick saving from text field itself TextArea longText = new TextArea(); // "Enter" is garbled here Hot to make the shortcut to work only in the from text field? Henri Kerola Use focus and blur listeners to remove and add the shortcut key: f.addFocusListener(new FocusListener() { @Override public void focus(FocusEvent event) { b.setClickShortcut(KeyCode.ENTER); } }); f.addBlurListener(new BlurListener() { @Override public void blur(BlurEvent event) { b.removeClickShortcut(); } }); Newer

Is Vaadin Elements meant to be used with the Vaadin Framework?

*爱你&永不变心* 提交于 2019-12-01 06:14:39
Vaadin seems to be pushing in 2 directions: Vaadin Framework (Java - Server-side) Vaadin Elements (Javascript - Client-side) Are they meant to be used together now.. or in the future? Or just 2 separate, unrelated product offerings? For example , is the Vaadin Grid Element (not to be confused with Vaadin 7's Java Grid ), meant to be used in 'Java-land'? I found this Server-side Elements post , which talks about creating/manipulating Javascript Web Components from the Server-side. Is this what we are meant to use? Or is there something else coming to simplify component usage in Java? ..I feel I

Is Vaadin Elements meant to be used with the Vaadin Framework?

前提是你 提交于 2019-12-01 05:14:38
问题 Vaadin seems to be pushing in 2 directions: Vaadin Framework (Java - Server-side) Vaadin Elements (Javascript - Client-side) Are they meant to be used together now.. or in the future? Or just 2 separate, unrelated product offerings? For example , is the Vaadin Grid Element (not to be confused with Vaadin 7's Java Grid), meant to be used in 'Java-land'? I found this Server-side Elements post, which talks about creating/manipulating Javascript Web Components from the Server-side. Is this what