|
1 <!DOCTYPE html> |
|
2 <html> |
|
3 <head> |
|
4 <title>HTML map accessible tree tests</title> |
|
5 <link rel="stylesheet" type="text/css" |
|
6 href="chrome://mochikit/content/tests/SimpleTest/test.css" /> |
|
7 |
|
8 <script type="application/javascript" |
|
9 src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script> |
|
10 |
|
11 <script type="application/javascript" |
|
12 src="../common.js"></script> |
|
13 <script type="application/javascript" |
|
14 src="../role.js"></script> |
|
15 |
|
16 <script type="application/javascript"> |
|
17 function doTest() |
|
18 { |
|
19 // map used as imagemap, not accessible |
|
20 var accTree = |
|
21 { SECTION: [ ] }; |
|
22 |
|
23 testAccessibleTree("imagemapcontainer", accTree); |
|
24 |
|
25 // map group. Imagemaps are inlines by default, so TEXT_CONTAINER. |
|
26 accTree = |
|
27 { TEXT_CONTAINER: [ |
|
28 { PARAGRAPH: [ |
|
29 { TEXT_LEAF: [ ] }, |
|
30 { LINK: [ |
|
31 { TEXT_LEAF: [ ] } |
|
32 ] }, |
|
33 { TEXT_LEAF: [ ] }, |
|
34 { LINK: [ |
|
35 { TEXT_LEAF: [ ] } |
|
36 ] }, |
|
37 { TEXT_LEAF: [ ] } |
|
38 ] } |
|
39 ] }; |
|
40 |
|
41 testAccessibleTree("mapgroup", accTree); |
|
42 |
|
43 SimpleTest.finish(); |
|
44 } |
|
45 |
|
46 SimpleTest.waitForExplicitFinish(); |
|
47 addA11yLoadEvent(doTest); |
|
48 </script> |
|
49 </head> |
|
50 <body> |
|
51 |
|
52 <a target="_blank" |
|
53 title="Map used for grouping is not accessible under certain circumstances" |
|
54 href="https://bugzilla.mozilla.org/show_bug.cgi?id=627718"> |
|
55 Mozilla Bug 627718 |
|
56 </a> |
|
57 <p id="display"></p> |
|
58 <div id="content" style="display: none"></div> |
|
59 <pre id="test"> |
|
60 </pre> |
|
61 |
|
62 <div id="imagemapcontainer"> |
|
63 <map name="atoz_map"> |
|
64 <area href="http://www.bbc.co.uk/radio4/atoz/index.shtml#b" |
|
65 coords="17,0,30,14" alt="b" shape="rect"> |
|
66 <area href="http://www.bbc.co.uk/radio4/atoz/index.shtml#a" |
|
67 coords="0,0,13,14" alt="a" shape="rect"> |
|
68 </map> |
|
69 </div> |
|
70 |
|
71 <img id="imgmap" width="447" height="15" |
|
72 usemap="#atoz_map" |
|
73 src="../letters.gif"> |
|
74 |
|
75 <map id="mapgroup" title="Navigation Bar" name="mapgroup"> |
|
76 <p> |
|
77 [<a href="#how">Bypass navigation bar</a>] |
|
78 [<a href="home.html">Home</a>] |
|
79 </p> |
|
80 </map> |
|
81 |
|
82 </body> |
|
83 </html> |