]> source.dussan.org Git - vaadin-framework.git/commitdiff
Modified the test case to be suitable
authorMatti Tahvonen <matti.tahvonen@itmill.com>
Tue, 7 Oct 2008 06:29:14 +0000 (06:29 +0000)
committerMatti Tahvonen <matti.tahvonen@itmill.com>
Tue, 7 Oct 2008 06:29:14 +0000 (06:29 +0000)
svn changeset:5600/svn branch:trunk

src/com/itmill/toolkit/tests/ScrollbarStressTest.java

index 1c755c6edfdebb5d40e6770255d376fa32c6d6c4..fd2a8ffb4944921918b7d29232413d6b8d4f8bfe 100644 (file)
@@ -77,33 +77,36 @@ public class ScrollbarStressTest extends Application {
     }
 
     private void drawInPanel() {
+        main.removeAllComponents();
         OrderedLayout ol = new OrderedLayout();
-        ol.setSizeFull();
-        main.setLayout(ol);
-        ol.addComponent(panel);
+        panel.setLayout(ol);
 
         ol = new OrderedLayout();
-        ol.setSizeFull();
         panel.setSizeFull();
         panel.setLayout(ol);
 
+        ol.setSizeFull();
+        ol.setWidth((String) width.getValue());
+        ol.setHeight((String) height.getValue());
+
         Label l = new Label("Label");
-        l.setWidth((String) width.getValue());
-        l.setHeight((String) height.getValue());
         l.setStyleName("no-padding");
+        l.setSizeFull();
 
         ol.addComponent(l);
+        main.addComponent(panel);
         main.removeWindow(subwindow);
     }
 
     private void drawInSubwindow() {
         main.removeAllComponents();
         OrderedLayout ol = new OrderedLayout();
-        ol.setSizeFull();
+        ol.setWidth((String) width.getValue());
+        ol.setHeight((String) height.getValue());
+
         Label l = new Label("Label");
-        l.setWidth((String) width.getValue());
-        l.setHeight((String) height.getValue());
         l.setStyleName("no-padding");
+        l.setSizeFull();
 
         ol.addComponent(l);
         subwindow.setLayout(ol);
@@ -111,14 +114,15 @@ public class ScrollbarStressTest extends Application {
     }
 
     private void drawInMainWindow() {
+        main.removeAllComponents();
         OrderedLayout ol = new OrderedLayout();
-        ol.setSizeFull();
         main.setLayout(ol);
+        ol.setWidth((String) width.getValue());
+        ol.setHeight((String) height.getValue());
 
         Label l = new Label("Label");
-        l.setWidth((String) width.getValue());
-        l.setHeight((String) height.getValue());
         l.setStyleName("no-padding");
+        l.setSizeFull();
 
         ol.addComponent(l);
         main.removeWindow(subwindow);