You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lo...@apache.org on 2011/03/18 21:04:17 UTC

svn commit: r1083034 - in /myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout: scrolling-2-levels.xhtml scrolling-box.xhtml scrolling-page.xhtml scrolling-panel-with-border.xhtml scrolling-panel.xhtml scrolling-tab.xhtml

Author: lofwyr
Date: Fri Mar 18 20:04:17 2011
New Revision: 1083034

URL: http://svn.apache.org/viewvc?rev=1083034&view=rev
Log:
scrolling tests

Added:
    myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-2-levels.xhtml
      - copied, changed from r1082502, myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml
    myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel-with-border.xhtml
      - copied, changed from r1082502, myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel.xhtml
    myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-tab.xhtml
      - copied, changed from r1082502, myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml
Modified:
    myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml
    myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-page.xhtml
    myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel.xhtml

Copied: myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-2-levels.xhtml (from r1082502, myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml)
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-2-levels.xhtml?p2=myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-2-levels.xhtml&p1=myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml&r1=1082502&r2=1083034&rev=1083034&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml (original)
+++ myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-2-levels.xhtml Fri Mar 18 20:04:17 2011
@@ -27,27 +27,35 @@
     <tc:box label="Scrolling test in a box" id="box">
       <tc:gridLayoutConstraint width="300px" height="600px"/>
       <f:facet name="layout">
-        <tc:gridLayout rows="auto;auto;auto"/>
+        <tc:gridLayout rows="100px;*"/>
       </f:facet>
 
-      <tc:image id="image-1" value="pidgeon-point.jpg">
-        <tc:gridLayoutConstraint minimumHeight="400px"/>
-      </tc:image>
-      <tc:image id="image-2" value="pidgeon-point.jpg">
-        <tc:gridLayoutConstraint minimumHeight="400px"/>
-      </tc:image>
-      <tc:image id="image-3" value="pidgeon-point.jpg">
-        <tc:gridLayoutConstraint minimumHeight="400px"/>
-      </tc:image>
-
-      <tc:script file="script/test-utils.js"/>
-
-      <tc:script onload="checkLayout('page:box', 0, 0, 300, 400);"/>
-
-      <tc:script onload="checkLayout('page:image-1', 0, 0, 300, 400);"/>
-      <tc:script onload="checkLayout('page:image-2', 0, 405, 300, 400);"/>
-      <tc:script onload="checkLayout('page:image-3', 0, 810, 300, 400);"/>
+      <tc:textarea id="text"/>
+
+
+      <tc:box label="Scrolling test in a box" id="box-2">
+        <f:facet name="layout">
+          <tc:gridLayout rows="100px;*"/>
+        </f:facet>
+
+        <tc:textarea id="text-2"/>
+
+        <tc:image id="image-1" value="pidgeon-point.jpg">
+          <tc:gridLayoutConstraint minimumHeight="600px"/>
+        </tc:image>
+
+      </tc:box>
+
 
     </tc:box>
+
+    <tc:script file="script/test-utils.js"/>
+
+    <tc:script onload="checkLayout('page:box', 0, 0, 300, 600);"/>
+
+    <tc:script onload="checkLayout('page:image-1', 6, 26, 287, 400);"/>
+    <tc:script onload="checkLayout('page:image-2', 6, 431, 287, 400);"/>
+    <tc:script onload="checkLayout('page:image-3', 6, 836, 287, 400);"/>
+
   </tc:page>
 </f:view>

Modified: myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml?rev=1083034&r1=1083033&r2=1083034&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml (original)
+++ myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml Fri Mar 18 20:04:17 2011
@@ -42,11 +42,11 @@
 
       <tc:script file="script/test-utils.js"/>
 
-      <tc:script onload="checkLayout('page:box', 0, 0, 300, 400);"/>
+      <tc:script onload="checkLayout('page:box', 0, 0, 300, 600);"/>
 
-      <tc:script onload="checkLayout('page:image-1', 0, 0, 300, 400);"/>
-      <tc:script onload="checkLayout('page:image-2', 0, 405, 300, 400);"/>
-      <tc:script onload="checkLayout('page:image-3', 0, 810, 300, 400);"/>
+      <tc:script onload="checkLayout('page:image-1', 6, 26, 287, 400);"/>
+      <tc:script onload="checkLayout('page:image-2', 6, 431, 287, 400);"/>
+      <tc:script onload="checkLayout('page:image-3', 6, 836, 287, 400);"/>
 
     </tc:box>
   </tc:page>

Modified: myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-page.xhtml
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-page.xhtml?rev=1083034&r1=1083033&r2=1083034&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-page.xhtml (original)
+++ myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-page.xhtml Fri Mar 18 20:04:17 2011
@@ -22,7 +22,7 @@
     xmlns:ui="http://java.sun.com/jsf/facelets"
     xmlns:f="http://java.sun.com/jsf/core">
 
-  <tc:page id="page">
+  <tc:page id="page" width="300px" height="600px">
     <tc:gridLayoutConstraint width="300px" height="600px"/>
     <f:facet name="layout">
       <tc:gridLayout rows="auto;auto;auto"/>
@@ -40,6 +40,8 @@
 
     <tc:script file="script/test-utils.js"/>
 
+    <tc:script onload="checkLayout('page::content', 0, 0, 300, 600);"/>
+
     <tc:script onload="checkLayout('page:image-1', 0, 0, 300, 400);"/>
     <tc:script onload="checkLayout('page:image-2', 0, 405, 300, 400);"/>
     <tc:script onload="checkLayout('page:image-3', 0, 810, 300, 400);"/>

Copied: myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel-with-border.xhtml (from r1082502, myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel.xhtml)
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel-with-border.xhtml?p2=myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel-with-border.xhtml&p1=myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel.xhtml&r1=1082502&r2=1083034&rev=1083034&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel.xhtml (original)
+++ myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel-with-border.xhtml Fri Mar 18 20:04:17 2011
@@ -25,10 +25,11 @@
   <tc:page id="page">
     <tc:gridLayoutConstraint width="300px" height="600px"/>
     <tc:panel id="panel">
-      <tc:gridLayoutConstraint width="300px" height="600px"/>
       <f:facet name="layout">
         <tc:gridLayout rows="auto;auto;auto"/>
       </f:facet>
+      <tc:gridLayoutConstraint width="300px" height="600px"
+                               borderLeft="10px" borderRight="10px" borderTop="10px" borderBottom="10px"/>
 
       <tc:image id="image-1" value="pidgeon-point.jpg">
         <tc:gridLayoutConstraint minimumHeight="400px"/>
@@ -42,9 +43,11 @@
 
       <tc:script file="script/test-utils.js"/>
 
-      <tc:script onload="checkLayout('page:image-1', 0, 0, 300, 400);"/>
-      <tc:script onload="checkLayout('page:image-2', 0, 405, 300, 400);"/>
-      <tc:script onload="checkLayout('page:image-3', 0, 810, 300, 400);"/>
+      <tc:script onload="checkLayout('page:panel', 0, 0, 300, 600);"/>
+
+      <tc:script onload="checkLayout('page:image-1', 10, 10, 280, 400);"/>
+      <tc:script onload="checkLayout('page:image-2', 10, 415, 280, 400);"/>
+      <tc:script onload="checkLayout('page:image-3', 10, 820, 280, 400);"/>
 
     </tc:panel>
   </tc:page>

Modified: myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel.xhtml
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel.xhtml?rev=1083034&r1=1083033&r2=1083034&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel.xhtml (original)
+++ myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-panel.xhtml Fri Mar 18 20:04:17 2011
@@ -42,6 +42,8 @@
 
       <tc:script file="script/test-utils.js"/>
 
+      <tc:script onload="checkLayout('page:panel', 0, 0, 300, 600);"/>
+
       <tc:script onload="checkLayout('page:image-1', 0, 0, 300, 400);"/>
       <tc:script onload="checkLayout('page:image-2', 0, 405, 300, 400);"/>
       <tc:script onload="checkLayout('page:image-3', 0, 810, 300, 400);"/>

Copied: myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-tab.xhtml (from r1082502, myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml)
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-tab.xhtml?p2=myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-tab.xhtml&p1=myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml&r1=1082502&r2=1083034&rev=1083034&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-box.xhtml (original)
+++ myfaces/tobago/trunk/tobago-example/tobago-example-test/src/main/webapp/tc/gridLayout/scrolling-tab.xhtml Fri Mar 18 20:04:17 2011
@@ -24,30 +24,35 @@
 
   <tc:page id="page">
     <tc:gridLayoutConstraint width="300px" height="600px"/>
-    <tc:box label="Scrolling test in a box" id="box">
-      <tc:gridLayoutConstraint width="300px" height="600px"/>
-      <f:facet name="layout">
-        <tc:gridLayout rows="auto;auto;auto"/>
-      </f:facet>
-
-      <tc:image id="image-1" value="pidgeon-point.jpg">
-        <tc:gridLayoutConstraint minimumHeight="400px"/>
-      </tc:image>
-      <tc:image id="image-2" value="pidgeon-point.jpg">
-        <tc:gridLayoutConstraint minimumHeight="400px"/>
-      </tc:image>
-      <tc:image id="image-3" value="pidgeon-point.jpg">
-        <tc:gridLayoutConstraint minimumHeight="400px"/>
-      </tc:image>
-
-      <tc:script file="script/test-utils.js"/>
-
-      <tc:script onload="checkLayout('page:box', 0, 0, 300, 400);"/>
-
-      <tc:script onload="checkLayout('page:image-1', 0, 0, 300, 400);"/>
-      <tc:script onload="checkLayout('page:image-2', 0, 405, 300, 400);"/>
-      <tc:script onload="checkLayout('page:image-3', 0, 810, 300, 400);"/>
+    <tc:tabGroup>
+      <tc:tab label="Scrolling test in a tab" id="tab1">
+        <tc:gridLayoutConstraint width="300px" height="600px"/>
+        <f:facet name="layout">
+          <tc:gridLayout rows="auto;auto;auto"/>
+        </f:facet>
+
+        <tc:image id="image-1" value="pidgeon-point.jpg">
+          <tc:gridLayoutConstraint minimumHeight="400px"/>
+        </tc:image>
+        <tc:image id="image-2" value="pidgeon-point.jpg">
+          <tc:gridLayoutConstraint minimumHeight="400px"/>
+        </tc:image>
+        <tc:image id="image-3" value="pidgeon-point.jpg">
+          <tc:gridLayoutConstraint minimumHeight="400px"/>
+        </tc:image>
+
+        <tc:script file="script/test-utils.js"/>
+
+        <tc:script onload="checkLayout('page:tab1::content', 0, 21, 300, 579);"/>
+
+        <!-- todo: Test result is 4 instead of 6. Why? -->
+        <tc:script onload="checkLayout('page:tab1:image-1', 6, 26, 288, 400);"/>
+        <!-- todo: Test result is 4 instead of 6. Why? -->
+        <tc:script onload="checkLayout('page:tab1:image-2', 6, 431, 288, 400);"/>
+        <!-- todo: Test result is 4 instead of 6. Why? -->
+        <tc:script onload="checkLayout('page:tab1:image-3', 6, 836, 288, 400);"/>
 
-    </tc:box>
+      </tc:tab>
+    </tc:tabGroup>
   </tc:page>
 </f:view>