OLD | NEW |
1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> | 1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <script> | 4 <script> |
5 | 5 |
6 function buildAccessibilityTree(accessibilityObject, indent, targetObject, t
argetString) { | 6 function buildAccessibilityTree(accessibilityObject, indent, targetObject, t
argetString) { |
7 var str = ""; | 7 var str = ""; |
8 for (var i = 0; i < indent; i++) | 8 for (var i = 0; i < indent; i++) |
9 str += " "; | 9 str += " "; |
10 str += accessibilityObject.role; | 10 str += accessibilityObject.role; |
11 str += " " + accessibilityObject.stringValue; | 11 str += " " + accessibilityObject.stringValue; |
12 if (targetObject && accessibilityObject.isEqual(targetObject)) | 12 if (targetObject && accessibilityObject.isEqual(targetObject)) |
13 str += " " + targetString; | 13 str += " " + targetString; |
14 str += "\n"; | 14 str += "\n"; |
15 document.getElementById("tree").innerText += str; | 15 document.getElementById("tree").innerText += str; |
16 | 16 |
17 if (accessibilityObject.stringValue.indexOf('End of test') >= 0) | 17 if (accessibilityObject.stringValue.indexOf('End of test') >= 0) |
18 return false; | 18 return false; |
19 | 19 |
20 var count = accessibilityObject.childrenCount; | 20 var count = accessibilityObject.childrenCount; |
21 for (var i = 0; i < count; ++i) { | 21 for (var i = 0; i < count; ++i) { |
22 if (!buildAccessibilityTree(accessibilityObject.childAtIndex(i), ind
ent + 1, targetObject, targetString)) | 22 if (!buildAccessibilityTree(accessibilityObject.childAtIndex(i), ind
ent + 1, targetObject, targetString)) |
23 return false; | 23 return false; |
24 } | 24 } |
25 | 25 |
26 return true; | 26 return true; |
27 } | 27 } |
28 </script> | 28 </script> |
29 <script src="../fast/js/resources/js-test-pre.js"></script> | 29 <script src="../resources/js-test.js"></script> |
30 </head> | 30 </head> |
31 <body id="body"> | 31 <body id="body"> |
32 | 32 |
33 <fieldset> | 33 <fieldset> |
34 <legend>Choose a shipping method:</legend> | 34 <legend>Choose a shipping method:</legend> |
35 <input id="overnight" type="radio" name="shipping" value="overnight" />Overn
ight | 35 <input id="overnight" type="radio" name="shipping" value="overnight" />Overn
ight |
36 </fieldset> | 36 </fieldset> |
37 | 37 |
38 <div>End of test</div> | 38 <div>End of test</div> |
39 | 39 |
(...skipping 21 matching lines...) Expand all Loading... |
61 var titleUIElementText = titleUIElement; | 61 var titleUIElementText = titleUIElement; |
62 while (titleUIElementText && titleUIElementText.childrenCount) | 62 while (titleUIElementText && titleUIElementText.childrenCount) |
63 titleUIElementText = titleUIElementText.childAtIndex(0); | 63 titleUIElementText = titleUIElementText.childAtIndex(0); |
64 | 64 |
65 shouldBe("titleUIElementText.stringValue", "'AXValue: Choose a shipping
method:'"); | 65 shouldBe("titleUIElementText.stringValue", "'AXValue: Choose a shipping
method:'"); |
66 } | 66 } |
67 </script> | 67 </script> |
68 | 68 |
69 </body> | 69 </body> |
70 </html> | 70 </html> |
OLD | NEW |