Refactoring: Pull all fullscreen code out of Document and into its own helper class
[WebKit-https.git] / LayoutTests / accessibility / onclick-handlers.html
1 <html>
2 <script>
3     if (window.testRunner)
4         testRunner.dumpAsText();
5 </script>
6 <body id="body">
7     
8     <div id="result"></div>
9     
10     <!-- This test checks that an element will expose AXPress as an action if it listens for onClick -->
11     <div onclick="alert('hello');">this is an on click handler</div>
12
13     <script>
14         if (window.accessibilityController) {
15             var result = document.getElementById("result");
16
17             var body = document.getElementById("body");
18             body.focus();
19             var focusedElement = accessibilityController.focusedElement;
20             var textElement = focusedElement.childAtIndex(0).childAtIndex(0);
21
22             if (textElement.isPressActionSupported()) {
23                 result.innerText += "Test passed\n";
24             }
25             else {
26                  result.innerText += "Test failed\n";
27             }
28         }
29     </script>
30 </body>
31 </html>