92e801c577889e2c9740ee225f37fbd75b4e31c4
[framework/web/webkit-efl.git] / LayoutTests / accessibility / image-map1.html
1 <html>
2 <head>
3 <link rel="stylesheet" href="../fast/js/resources/js-test-style.css">
4 <script>
5 var successfullyParsed = false;
6 </script>
7 <script src="../fast/js/resources/js-test-pre.js"></script>
8 </head>
9 <script>
10     if (window.layoutTestController)
11         layoutTestController.dumpAsText();
12 </script>
13 <body id="body">
14     
15     <!-- Test image map -->
16     <map id="apple" name="imagemap1">
17       <area shape="rect" coords="10,10,133,72" href="http://www.apple.com" title="Link1" />
18       <area shape="rect" coords="12,74,134,88" href="http://www.apple.com" title="Link2" />
19       <area shape="rect" coords="11,91,133,105" href="http://www.apple.com" title="Link3" />
20       <area shape="default" nohref="nohref" alt="" />
21     </map>
22
23     <img src="resources/cake.png"  border="0" align="left" usemap="#imagemap1" vspace="1">
24
25 <p id="description"></p>
26 <div id="console"></div>
27      
28     <script>
29         description("This tests that you can reach the links within an image map.");
30
31         if (window.accessibilityController) {
32             document.getElementById("body").focus();
33
34             var body = accessibilityController.focusedElement;
35             shouldBe("body.childAtIndex(0).role", "'AXRole: AXLink'");
36             shouldBe("body.childAtIndex(0).title", "'AXTitle: Link1'");
37
38             shouldBe("body.childAtIndex(1).role", "'AXRole: AXLink'");
39             shouldBe("body.childAtIndex(1).title", "'AXTitle: Link2'");
40
41             shouldBe("body.childAtIndex(2).role", "'AXRole: AXLink'");
42             shouldBe("body.childAtIndex(2).title", "'AXTitle: Link3'");
43         }
44    successfullyParsed = true;
45 </script>
46
47 <script src="../fast/js/resources/js-test-post.js"></script>
48 </body>
49 </html>