From 7b25b3886ea95bc6495506fbe9472e45fcbde684 Mon Sep 17 00:00:00 2001 From: Artur Signell Date: Thu, 30 Aug 2012 17:24:36 +0300 Subject: Renamed tests -> uitest and tests/testbench -> uitest/src (#9299) --- .../src/com/vaadin/tests/tickets/Ticket2002.java | 51 ++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 uitest/src/com/vaadin/tests/tickets/Ticket2002.java (limited to 'uitest/src/com/vaadin/tests/tickets/Ticket2002.java') diff --git a/uitest/src/com/vaadin/tests/tickets/Ticket2002.java b/uitest/src/com/vaadin/tests/tickets/Ticket2002.java new file mode 100644 index 0000000000..aeaf3bfb33 --- /dev/null +++ b/uitest/src/com/vaadin/tests/tickets/Ticket2002.java @@ -0,0 +1,51 @@ +package com.vaadin.tests.tickets; + +import com.vaadin.Application; +import com.vaadin.data.util.MethodProperty; +import com.vaadin.ui.GridLayout; +import com.vaadin.ui.UI.LegacyWindow; +import com.vaadin.ui.TextField; + +public class Ticket2002 extends Application.LegacyApplication { + private Long long1 = new Long(1L); + private Long long2 = new Long(2L); + + public Long getLong1() { + return long1; + } + + public void setLong1(Long long1) { + this.long1 = long1; + } + + public Long getLong2() { + return long2; + } + + public void setLong2(Long long2) { + this.long2 = long2; + } + + @Override + public void init() { + LegacyWindow w = new LegacyWindow(getClass().getName()); + setMainWindow(w); + + GridLayout layout = new GridLayout(2, 2); + layout.setSpacing(true); + + TextField f1 = new TextField("Non-immediate/Long text field", + new MethodProperty(this, "long1")); + f1.setImmediate(false); + f1.setNullSettingAllowed(true); + TextField f2 = new TextField("Immediate/Long text field", + new MethodProperty(this, "long2")); + f2.setImmediate(true); + f2.setNullSettingAllowed(true); + + layout.addComponent(f1); + layout.addComponent(f2); + + w.setContent(layout); + } +} -- cgit v1.2.3