| <html> | |
| <head> | |
| <script src="../fast/js/resources/js-test-pre.js"></script> | |
| </head> | |
| <script> | |
| if (window.testRunner) | |
| testRunner.dumpAsText(); | |
| </script> | |
| <body id="body"> | |
| <!-- Test image map --> | |
| <map id="apple" name="imagemap1"> | |
| <area shape="rect" coords="10,10,133,72" href="http://www.apple.com" title="Link1" /> | |
| <area shape="rect" coords="12,74,134,88" href="http://www.apple.com" title="Link2" /> | |
| <area shape="rect" coords="11,91,133,105" href="http://www.apple.com" title="Link3" /> | |
| <area shape="default" nohref="nohref" alt="" /> | |
| </map> | |
| <img src="resources/cake.png" border="0" align="left" usemap="#imagemap1" vspace="1"> | |
| <p id="description"></p> | |
| <div id="console"></div> | |
| <script> | |
| description("This tests that you can reach the links within an image map."); | |
| if (window.accessibilityController) { | |
| document.getElementById("body").focus(); | |
| var body = accessibilityController.focusedElement; | |
| shouldBe("body.childAtIndex(0).role", "'AXRole: AXLink'"); | |
| shouldBe("body.childAtIndex(0).title", "'AXTitle: Link1'"); | |
| shouldBe("body.childAtIndex(1).role", "'AXRole: AXLink'"); | |
| shouldBe("body.childAtIndex(1).title", "'AXTitle: Link2'"); | |
| shouldBe("body.childAtIndex(2).role", "'AXRole: AXLink'"); | |
| shouldBe("body.childAtIndex(2).title", "'AXTitle: Link3'"); | |
| } | |
| </script> | |
| <script src="../fast/js/resources/js-test-post.js"></script> | |
| </body> | |
| </html> |