Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
michael@0 | 1 | <?xml version="1.0"?> |
michael@0 | 2 | <?xml-stylesheet href="chrome://global/skin" type="text/css"?> |
michael@0 | 3 | <?xml-stylesheet href="chrome://mochikit/content/tests/SimpleTest/test.css" |
michael@0 | 4 | type="text/css"?> |
michael@0 | 5 | |
michael@0 | 6 | <window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" |
michael@0 | 7 | title="Table header information cells for XUL listbox"> |
michael@0 | 8 | |
michael@0 | 9 | <script type="application/javascript" |
michael@0 | 10 | src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js" /> |
michael@0 | 11 | |
michael@0 | 12 | <script type="application/javascript" |
michael@0 | 13 | src="../common.js"></script> |
michael@0 | 14 | <script type="application/javascript" |
michael@0 | 15 | src="../table.js"></script> |
michael@0 | 16 | |
michael@0 | 17 | <script type="application/javascript"> |
michael@0 | 18 | <![CDATA[ |
michael@0 | 19 | function doTest() |
michael@0 | 20 | { |
michael@0 | 21 | ////////////////////////////////////////////////////////////////////////// |
michael@0 | 22 | // XUL listbox |
michael@0 | 23 | |
michael@0 | 24 | var headerInfoMap = [ |
michael@0 | 25 | { |
michael@0 | 26 | cell: "lb1_cell0", |
michael@0 | 27 | rowHeaderCells: [], |
michael@0 | 28 | columnHeaderCells: [ "lb1_header1" ] |
michael@0 | 29 | }, |
michael@0 | 30 | { |
michael@0 | 31 | cell: "lb1_cell1", |
michael@0 | 32 | rowHeaderCells: [], |
michael@0 | 33 | columnHeaderCells: [ "lb1_header2" ] |
michael@0 | 34 | }, |
michael@0 | 35 | { |
michael@0 | 36 | cell: "lb1_cell2", |
michael@0 | 37 | rowHeaderCells: [], |
michael@0 | 38 | columnHeaderCells: [ "lb1_header3" ] |
michael@0 | 39 | }, |
michael@0 | 40 | { |
michael@0 | 41 | cell: "lb1_cell3", |
michael@0 | 42 | rowHeaderCells: [], |
michael@0 | 43 | columnHeaderCells: [ "lb1_header1" ] |
michael@0 | 44 | }, |
michael@0 | 45 | { |
michael@0 | 46 | cell: "lb1_cell4", |
michael@0 | 47 | rowHeaderCells: [], |
michael@0 | 48 | columnHeaderCells: [ "lb1_header2" ] |
michael@0 | 49 | }, |
michael@0 | 50 | { |
michael@0 | 51 | cell: "lb1_cell5", |
michael@0 | 52 | rowHeaderCells: [], |
michael@0 | 53 | columnHeaderCells: [ "lb1_header3" ] |
michael@0 | 54 | }, |
michael@0 | 55 | ]; |
michael@0 | 56 | |
michael@0 | 57 | testHeaderCells(headerInfoMap); |
michael@0 | 58 | |
michael@0 | 59 | ////////////////////////////////////////////////////////////////////////// |
michael@0 | 60 | // XUL listbox with ARIA |
michael@0 | 61 | |
michael@0 | 62 | headerInfoMap = [ |
michael@0 | 63 | { |
michael@0 | 64 | cell: "lb2_cell0", |
michael@0 | 65 | rowHeaderCells: [], |
michael@0 | 66 | columnHeaderCells: [] |
michael@0 | 67 | }, |
michael@0 | 68 | { |
michael@0 | 69 | cell: "lb2_cell1", |
michael@0 | 70 | rowHeaderCells: [], |
michael@0 | 71 | columnHeaderCells: [] |
michael@0 | 72 | }, |
michael@0 | 73 | { |
michael@0 | 74 | cell: "lb2_cell2", |
michael@0 | 75 | rowHeaderCells: [], |
michael@0 | 76 | columnHeaderCells: [] |
michael@0 | 77 | }, |
michael@0 | 78 | { |
michael@0 | 79 | cell: "lb2_cell3", |
michael@0 | 80 | rowHeaderCells: [], |
michael@0 | 81 | columnHeaderCells: [ "lb2_cell0" ] |
michael@0 | 82 | }, |
michael@0 | 83 | { |
michael@0 | 84 | cell: "lb2_cell4", |
michael@0 | 85 | rowHeaderCells: [ "lb2_cell3" ], |
michael@0 | 86 | columnHeaderCells: [ "lb2_cell1" ] |
michael@0 | 87 | }, |
michael@0 | 88 | { |
michael@0 | 89 | cell: "lb2_cell5", |
michael@0 | 90 | rowHeaderCells: [ "lb2_cell3" ], |
michael@0 | 91 | columnHeaderCells: [ "lb2_cell2" ] |
michael@0 | 92 | }, |
michael@0 | 93 | { |
michael@0 | 94 | cell: "lb2_cell6", |
michael@0 | 95 | rowHeaderCells: [], |
michael@0 | 96 | columnHeaderCells: [ "lb2_cell0" ] |
michael@0 | 97 | }, |
michael@0 | 98 | { |
michael@0 | 99 | cell: "lb2_cell7", |
michael@0 | 100 | rowHeaderCells: [ "lb2_cell6" ], |
michael@0 | 101 | columnHeaderCells: [ "lb2_cell1" ] |
michael@0 | 102 | }, |
michael@0 | 103 | { |
michael@0 | 104 | cell: "lb2_cell8", |
michael@0 | 105 | rowHeaderCells: [ "lb2_cell6" ], |
michael@0 | 106 | columnHeaderCells: [ "lb2_cell2" ] |
michael@0 | 107 | } |
michael@0 | 108 | ]; |
michael@0 | 109 | |
michael@0 | 110 | testHeaderCells(headerInfoMap); |
michael@0 | 111 | |
michael@0 | 112 | SimpleTest.finish(); |
michael@0 | 113 | } |
michael@0 | 114 | |
michael@0 | 115 | SimpleTest.waitForExplicitFinish(); |
michael@0 | 116 | addA11yLoadEvent(doTest); |
michael@0 | 117 | ]]> |
michael@0 | 118 | </script> |
michael@0 | 119 | |
michael@0 | 120 | <hbox style="overflow: auto;"> |
michael@0 | 121 | <body xmlns="http://www.w3.org/1999/xhtml"> |
michael@0 | 122 | <a target="_blank" |
michael@0 | 123 | href="https://bugzilla.mozilla.org/show_bug.cgi?id=512424" |
michael@0 | 124 | title="implement IAccessibleTable2"> |
michael@0 | 125 | Mozilla Bug 512424 |
michael@0 | 126 | </a> |
michael@0 | 127 | |
michael@0 | 128 | <p id="display"></p> |
michael@0 | 129 | <div id="content" style="display: none"> |
michael@0 | 130 | </div> |
michael@0 | 131 | <pre id="test"> |
michael@0 | 132 | </pre> |
michael@0 | 133 | </body> |
michael@0 | 134 | |
michael@0 | 135 | <vbox flex="1"> |
michael@0 | 136 | |
michael@0 | 137 | <label control="listbox" value="multicolumn listbox with header"/> |
michael@0 | 138 | <listbox id="listbox"> |
michael@0 | 139 | <listhead> |
michael@0 | 140 | <listheader id="lb1_header1" label="header1"/> |
michael@0 | 141 | <listheader id="lb1_header2" label="header2"/> |
michael@0 | 142 | <listheader id="lb1_header3" label="header3"/> |
michael@0 | 143 | </listhead> |
michael@0 | 144 | <listcols> |
michael@0 | 145 | <listcol flex="1"/> |
michael@0 | 146 | <listcol flex="1"/> |
michael@0 | 147 | <listcol flex="1"/> |
michael@0 | 148 | </listcols> |
michael@0 | 149 | <listitem> |
michael@0 | 150 | <listcell id="lb1_cell0" label="cell0"/> |
michael@0 | 151 | <listcell id="lb1_cell1" label="cell1"/> |
michael@0 | 152 | <listcell id="lb1_cell2" label="cell2"/> |
michael@0 | 153 | </listitem> |
michael@0 | 154 | <listitem> |
michael@0 | 155 | <listcell id="lb1_cell3" label="cell3"/> |
michael@0 | 156 | <listcell id="lb1_cell4" label="cell4"/> |
michael@0 | 157 | <listcell id="lb1_cell5" label="cell5"/> |
michael@0 | 158 | </listitem> |
michael@0 | 159 | <listitem> |
michael@0 | 160 | <listcell id="lb1_cell6" label="cell6"/> |
michael@0 | 161 | <listcell id="lb1_cell7" label="cell7"/> |
michael@0 | 162 | <listcell id="lb1_cell8" label="cell8"/> |
michael@0 | 163 | </listitem> |
michael@0 | 164 | </listbox> |
michael@0 | 165 | |
michael@0 | 166 | <label control="listbox2" value="multicolumn listbox with ARIA headers"/> |
michael@0 | 167 | <listbox id="listbox2"> |
michael@0 | 168 | <listcols> |
michael@0 | 169 | <listcol flex="1"/> |
michael@0 | 170 | <listcol flex="1"/> |
michael@0 | 171 | <listcol flex="1"/> |
michael@0 | 172 | </listcols> |
michael@0 | 173 | <listitem> |
michael@0 | 174 | <listcell role="columnheader" id="lb2_cell0" label="cell0"/> |
michael@0 | 175 | <listcell role="columnheader" id="lb2_cell1" label="cell1"/> |
michael@0 | 176 | <listcell role="columnheader" id="lb2_cell2" label="cell2"/> |
michael@0 | 177 | </listitem> |
michael@0 | 178 | <listitem> |
michael@0 | 179 | <listcell role="rowheader" id="lb2_cell3" label="cell3"/> |
michael@0 | 180 | <listcell id="lb2_cell4" label="cell4"/> |
michael@0 | 181 | <listcell id="lb2_cell5" label="cell5"/> |
michael@0 | 182 | </listitem> |
michael@0 | 183 | <listitem> |
michael@0 | 184 | <listcell role="rowheader" id="lb2_cell6" label="cell6"/> |
michael@0 | 185 | <listcell id="lb2_cell7" label="cell7"/> |
michael@0 | 186 | <listcell id="lb2_cell8" label="cell8"/> |
michael@0 | 187 | </listitem> |
michael@0 | 188 | </listbox> |
michael@0 | 189 | |
michael@0 | 190 | </vbox> |
michael@0 | 191 | </hbox> |
michael@0 | 192 | |
michael@0 | 193 | </window> |
michael@0 | 194 |