From aca92f4937cc54f122b20c4bfb6288ee007c9e47 Mon Sep 17 00:00:00 2001 From: Henri Sara Date: Wed, 14 Nov 2012 13:49:47 +0200 Subject: Panel and Window based on AbstractSingleComponentContainer (#2924) Change-Id: I9eb1f40a02dcad0f756ad2518d86ef1c52aa69c2 --- uitest/src/com/vaadin/tests/tickets/Ticket677.java | 32 ++++++++++++++-------- 1 file changed, 21 insertions(+), 11 deletions(-) (limited to 'uitest/src/com/vaadin/tests/tickets/Ticket677.java') diff --git a/uitest/src/com/vaadin/tests/tickets/Ticket677.java b/uitest/src/com/vaadin/tests/tickets/Ticket677.java index e32c25ff48..44ec3d10da 100644 --- a/uitest/src/com/vaadin/tests/tickets/Ticket677.java +++ b/uitest/src/com/vaadin/tests/tickets/Ticket677.java @@ -20,6 +20,7 @@ import com.vaadin.ui.LegacyWindow; import com.vaadin.ui.Panel; import com.vaadin.ui.Table; import com.vaadin.ui.TextField; +import com.vaadin.ui.VerticalLayout; public class Ticket677 extends LegacyApplication { @@ -83,34 +84,43 @@ public class Ticket677 extends LegacyApplication { } })); - root.setContent(new GridLayout(2, 3)); + GridLayout content = new GridLayout(2, 3); + root.setContent(content); main.addComponent(root); TextField tf = new TextField("Enabled"); tf.setImmediate(true); - root.addComponent(tf); + content.addComponent(tf); tf = new TextField("Disabled"); tf.setImmediate(true); tf.setEnabled(false); - root.addComponent(tf); + content.addComponent(tf); - root.addComponent(one); + VerticalLayout oneLayout = new VerticalLayout(); + oneLayout.setMargin(true); + one.setContent(oneLayout); + + content.addComponent(one); tf = new TextField("Enabled"); tf.setImmediate(true); - one.addComponent(tf); + oneLayout.addComponent(tf); tf = new TextField("Disabled"); tf.setImmediate(true); tf.setEnabled(false); - one.addComponent(tf); + oneLayout.addComponent(tf); + + VerticalLayout twoLayout = new VerticalLayout(); + twoLayout.setMargin(true); + two.setContent(twoLayout); - root.addComponent(two); + content.addComponent(two); tf = new TextField("Enabled"); tf.setImmediate(true); - two.addComponent(tf); + twoLayout.addComponent(tf); tf = new TextField("Disabled"); tf.setImmediate(true); tf.setEnabled(false); - two.addComponent(tf); + twoLayout.addComponent(tf); form = new Form(); form.setCaption("Enabled"); @@ -126,7 +136,7 @@ public class Ticket677 extends LegacyApplication { }); form.setItemDataSource(new BeanItem(new MyBean())); - root.addComponent(form); + content.addComponent(form); table = new Table("Enabled"); table.setPageLength(7); @@ -154,7 +164,7 @@ public class Ticket677 extends LegacyApplication { }); table.setEditable(true); - root.addComponent(table); + content.addComponent(table); } -- cgit v1.2.3