summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorMatti Tahvonen <matti.tahvonen@itmill.com>2009-10-28 10:11:27 +0000
committerMatti Tahvonen <matti.tahvonen@itmill.com>2009-10-28 10:11:27 +0000
commit08cc349e8b4e81f5f5f3c037417d32d661bd09d7 (patch)
treeaa7390b861ace66f9fb88be9c6aac7b574d8cee1 /tests
parentc0e9e16c3fe44b7ed555ac6a5681d8df9d45b0e2 (diff)
downloadvaadin-framework-08cc349e8b4e81f5f5f3c037417d32d661bd09d7.tar.gz
vaadin-framework-08cc349e8b4e81f5f5f3c037417d32d661bd09d7.zip
merged [9424] (partly by hand because of source folder refactoring) from 6.1
svn changeset:9425/svn branch:6.2
Diffstat (limited to 'tests')
-rw-r--r--tests/src/com/vaadin/tests/components/form/FormWithRelativelySizedLayout.java52
1 files changed, 52 insertions, 0 deletions
diff --git a/tests/src/com/vaadin/tests/components/form/FormWithRelativelySizedLayout.java b/tests/src/com/vaadin/tests/components/form/FormWithRelativelySizedLayout.java
new file mode 100644
index 0000000000..17fe4477c3
--- /dev/null
+++ b/tests/src/com/vaadin/tests/components/form/FormWithRelativelySizedLayout.java
@@ -0,0 +1,52 @@
+package com.vaadin.tests.components.form;
+
+import com.vaadin.tests.components.TestBase;
+import com.vaadin.ui.Button;
+import com.vaadin.ui.Component;
+import com.vaadin.ui.CssLayout;
+import com.vaadin.ui.Form;
+import com.vaadin.ui.Label;
+
+public class FormWithRelativelySizedLayout extends TestBase {
+
+ @Override
+ protected String getDescription() {
+ return "Forms mainlayouts relative height should be everyting left out from footer and possible borders/paddings. ";
+ }
+
+ @Override
+ protected Integer getTicketNumber() {
+ return 3488;
+ }
+
+ @Override
+ protected void setup() {
+
+ Form f = new Form();
+ f.setCaption("Form, full size");
+
+ f.setWidth("100%");
+ f.setHeight("100%");
+
+ Label l = new Label(
+ "This green label should consume all available space, pushing ok button to bottom of the view");
+ l.setSizeFull();
+
+ CssLayout lo = new CssLayout() {
+ @Override
+ protected String getCss(Component c) {
+ return "background: green;color:red;";
+ }
+ };
+ lo.setSizeFull();
+
+ f.setLayout(lo);
+ lo.addComponent(l);
+
+ f.getFooter().addComponent(new Button("OK button"));
+
+ getLayout().setSizeFull();
+ getLayout().addComponent(f);
+ }
+
+}