| OLD | NEW |
| (Empty) |
| 1 <html> | |
| 2 <head> | |
| 3 <script src="../fast/js/resources/js-test-pre.js"></script> | |
| 4 | |
| 5 <script> | |
| 6 | |
| 7 if (window.testRunner) | |
| 8 testRunner.waitUntilDone(); | |
| 9 | |
| 10 function buildAccessibilityTree(accessibilityObject, indent) { | |
| 11 var count = accessibilityObject.childrenCount; | |
| 12 for (var i = 0; i < count; ++i) { | |
| 13 if (!buildAccessibilityTree(accessibilityObject.childAtIndex(i), indent
+ 1)) | |
| 14 return false; | |
| 15 } | |
| 16 | |
| 17 return true; | |
| 18 } | |
| 19 | |
| 20 function runAXTest() { | |
| 21 | |
| 22 | |
| 23 description("This tests that an image map's hold on it's parent will be clear
ed if the parent goes away."); | |
| 24 | |
| 25 // First access all children using AX | |
| 26 buildAccessibilityTree(accessibilityController.rootElement, 0); | |
| 27 | |
| 28 var child = document.getElementById('img'); child.parentNode.removeChild(chil
d); | |
| 29 | |
| 30 // Now verify we haven't crashed. | |
| 31 buildAccessibilityTree(accessibilityController.rootElement, 0); | |
| 32 | |
| 33 if (window.testRunner) | |
| 34 testRunner.notifyDone(); | |
| 35 } | |
| 36 </script> | |
| 37 | |
| 38 </head> | |
| 39 <body> | |
| 40 | |
| 41 <map name="map"> | |
| 42 <div id="o7"></div> | |
| 43 <area id="o20" href="#"></area></map> | |
| 44 | |
| 45 <img id="img" usemap="#map"><span></span> | |
| 46 | |
| 47 <script>setTimeout("runAXTest();", 1);</script> | |
| 48 | |
| 49 <p id="description"></p> | |
| 50 <div id="console"></div> | |
| 51 | |
| 52 </body> | |
| 53 </html> | |
| OLD | NEW |