MediaPlayerPrivateAVFoundationObjC's "periodic time observer" is unnecessary
[WebKit-https.git] / LayoutTests / accessibility / language-attribute.html
1 <html>
2 <script>
3     if (window.layoutTestController)
4         layoutTestController.dumpAsText();
5 </script>
6 <head>
7 <meta http-equiv="content-language" content="en-gb"> 
8 <body id="body">
9
10     <!-- This tests the ability to get the content language for various elements using various techniques -->
11
12     cheerio
13     
14     <p lang="de">germannish</p>
15     <p lang="ja">elvish</p>
16
17     and more english
18
19     <div id="result"></div>
20     
21     <script>
22         if (window.accessibilityController) {
23             var body = document.getElementById("body");
24             body.focus();
25             var webArea = accessibilityController.focusedElement;
26             var result = document.getElementById("result");
27
28             var text1 = webArea.childAtIndex(0).childAtIndex(0);
29             var text2 = webArea.childAtIndex(1).childAtIndex(0);
30             var text3 = webArea.childAtIndex(2).childAtIndex(0);
31             var text4 = webArea.childAtIndex(3).childAtIndex(0);
32
33             if ( webArea.language == "AXLanguage: en-gb" && text1.language == "AXLanguage: en-gb" && 
34                  text2.language == "AXLanguage: de" && text3.language == "AXLanguage: ja" && 
35                  text4.language == "AXLanguage: en-gb") {
36                result.innerText = "Passed";
37             }
38             else { 
39                result.innerText = "Failed. Could not find AXLanguages: " + webArea.language + " - " + text1.language;
40             }
41         }
42     </script>
43 </body>
44 </html>