PageRenderTime 26ms CodeModel.GetById 16ms app.highlight 4ms RepoModel.GetById 1ms app.codeStats 0ms

/toolkit/content/tests/chrome/test_tree_hier.xul

http://github.com/zpao/v8monkey
Unknown | 136 lines | 129 code | 7 blank | 0 comment | 0 complexity | 744402fcdebf1a5d4173c1f9607ac8cc MD5 | raw file
  1<?xml version="1.0"?>
  2<?xml-stylesheet href="chrome://global/skin" type="text/css"?>
  3<?xml-stylesheet href="chrome://mochikit/content/tests/SimpleTest/test.css" type="text/css"?>
  4<!--
  5  XUL Widget Test for hierarchical tree
  6  -->
  7<window title="Hierarchical Tree" width="500" height="600"
  8        onload="setTimeout(testtag_tree, 0, 'tree-hier', 'treechildren-hier', 'multiple', '', 'hierarchical tree');"
  9        xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
 10  <script type="application/javascript" src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script>  
 11  <script type="application/javascript" src="chrome://mochikit/content/tests/SimpleTest/EventUtils.js"></script>  
 12
 13<script src="tree_shared.js"/>
 14
 15<tree id="tree-hier" rows="4">
 16  <treecols>
 17    <treecol id="name" label="Name" primary="true"
 18             sort="label" properties="one two" flex="1"/>
 19    <treecol id="address" label="Address" flex="2"/>
 20    <treecol id="planet" label="Planet" flex="1"/>
 21    <treecol id="gender" label="Gender" flex="1" cycler="true"/>
 22  </treecols>
 23  <treechildren id="treechildren-hier">
 24    <treeitem>
 25      <treerow properties="firstrow">
 26        <treecell label="Mary" value="mary" properties="firstname"/>
 27        <treecell label="206 Garden Avenue" value="206ga"/>
 28        <treecell label="Earth"/>
 29        <treecell label="Female" value="f"/>
 30      </treerow>
 31    </treeitem>
 32    <treeitem>
 33      <treerow>
 34        <treecell/>
 35        <treecell value="19ms"/>
 36        <treecell label="Earth"/>
 37        <treecell label="Male" value="m"/>
 38      </treerow>
 39    </treeitem>
 40    <treeitem container="true">
 41      <treerow>
 42        <treecell label="Sarah"/>
 43        <treecell label="702 Fern Avenue" editable="false"/>
 44        <treecell label="Saturn"/>
 45        <treecell label="Female" value="f"/>
 46      </treerow>
 47      <treechildren>
 48        <treeitem>
 49          <treerow>
 50            <treecell label="Mary"/>
 51            <treecell label="206 Garden Avenue"/>
 52            <treecell label="Female" value="f"/>
 53            <treecell label="Neptune"/>
 54          </treerow>
 55        </treeitem>
 56        <treeitem>
 57          <treerow>
 58            <treecell label="Chris"/>
 59            <treecell label="19 Marion Street"/>
 60            <treecell label="Omicron Persei 8"/>
 61            <treecell label="Male" value="m"/>
 62          </treerow>
 63        </treeitem>
 64        <treeitem>
 65          <treerow>
 66            <treecell label="Sarah"/>
 67            <treecell label="702 Fern Avenue" editable="false"/>
 68            <treecell label="Earth"/>
 69            <treecell label="Female" value="f"/>
 70          </treerow>
 71        </treeitem>
 72        <treeitem>
 73          <treerow>
 74            <treecell label="John"/>
 75            <treecell label="99 Westminster Avenue"/>
 76            <treecell label="Neptune"/>
 77            <treecell label="Male" value="m"/>
 78          </treerow>
 79        </treeitem>
 80      </treechildren>
 81    </treeitem>
 82    <treeitem>
 83      <treerow>
 84        <treecell label="John"/>
 85        <treecell label="99 Westminster Avenue"/>
 86        <treecell/>
 87        <treecell label="Male" value="m"/>
 88      </treerow>
 89    </treeitem>
 90    <treeitem>
 91      <treerow>
 92        <treecell label="Mary"/>
 93        <treecell label="206 Garden Avenue" selectable="false"/>
 94        <treecell label=""/>
 95        <treecell label="Female" value="f"/>
 96      </treerow>
 97    </treeitem>
 98    <treeitem>
 99      <treerow>
100        <treecell label="Chris"/>
101        <treecell label="19 Marion Street"/>
102        <treecell label="Neptune"/>
103        <treecell label="Male" value="m"/>
104      </treerow>
105    </treeitem>
106    <treeitem>
107      <treerow>
108        <treecell label="Sarah"/>
109        <treecell label="702 Fern Avenue"/>
110        <treecell label="Earth"/>
111        <treecell label="Female" value="f"/>
112      </treerow>
113    </treeitem>
114    <treeitem>
115      <treerow>
116        <treecell label="John"/>
117        <treecell label="99 Westminster Avenue"/>
118        <treecell label="Mars"/>
119        <treecell label="Male" value="m"/>
120      </treerow>
121    </treeitem>
122  </treechildren>
123</tree>
124
125  <!-- test results are displayed in the html:body -->
126  <body xmlns="http://www.w3.org/1999/xhtml" style="height: 300px; overflow: auto;"/>
127
128  <!-- test code goes here -->
129  <script type="application/javascript"><![CDATA[
130
131SimpleTest.waitForExplicitFinish();
132
133]]>
134</script>
135
136</window>