Fix keypad issue when ime context transit to another context
[framework/web/webkit-efl.git] / LayoutTests / accessibility / aria-hidden-update.html
1 <html>
2 <html>
3 <head>
4 <script src="../fast/js/resources/js-test-pre.js"></script>
5 </head>
6 <body id="body">
7  
8     <div role="group" tabindex="0" id="parent">
9     <div role="button" id="button1" tabindex="0">Button 1</div>
10     <div role="button" id="button2" tabindex="0">Button 2</div>
11     <div role="button" id="button3" tabindex="0">Button 3</div>
12
13     </div>
14
15
16     <p id="description"></p>
17     <div id="console"></div>
18      
19     <script>
20         if (window.accessibilityController) {
21             description("This test makes sure that when aria-hidden changes, the AX hierarchy is updated.");
22
23             // Get the parent element.
24             document.getElementById("parent").focus();
25             var parent = accessibilityController.focusedElement;
26             
27             // Get all three children.
28             document.getElementById("button1").focus();
29             var button1 = accessibilityController.focusedElement;
30             document.getElementById("button2").focus();
31             var button2 = accessibilityController.focusedElement;
32             document.getElementById("button3").focus();
33             var button3 = accessibilityController.focusedElement;
34       
35             // Verify that the 3 children are present.
36             shouldBeTrue("parent.childAtIndex(0).isEqual(button1)");
37             shouldBeTrue("parent.childAtIndex(1).isEqual(button2)");
38             shouldBeTrue("parent.childAtIndex(2).isEqual(button3)");
39
40             // Make the 2nd button hidden. Only 1 and 3 should be present.
41             document.getElementById("button2").setAttribute("aria-hidden", "true");
42             shouldBeTrue("parent.childAtIndex(0).isEqual(button1)");
43             shouldBeTrue("parent.childAtIndex(1).isEqual(button3)");
44            
45             // Make the 1st button hidden. Only 3 should be present.
46             document.getElementById("button1").setAttribute("aria-hidden", "true");
47             shouldBeTrue("parent.childAtIndex(0).isEqual(button3)");
48
49             // Make the 2nd button not hidden. 2 and 3 should be present.
50             document.getElementById("button2").setAttribute("aria-hidden", "false");
51             shouldBeTrue("parent.childAtIndex(0).isEqual(button2)");
52             shouldBeTrue("parent.childAtIndex(1).isEqual(button3)");
53
54         }
55     </script>
56
57 <script src="../fast/js/resources/js-test-post.js"></script>
58 </body>
59 </html>