Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(110)

Side by Side Diff: LayoutTests/accessibility/menu-list-popup-reuses-objects.html

Issue 1061063004: Revert of Don't keep recreating AXMenuListPopup (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@suppress_extra_events
Patch Set: Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | LayoutTests/accessibility/menu-list-popup-reuses-objects-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE HTML>
2 <html>
3 <body>
4 <script src="../resources/js-test.js"></script>
5
6 <select id="menulist">
7 <option id="item0">Alicia</option>
8 <option id="item1">Peter</option>
9 <option id="item2">Kalinda</option>
10 </select>
11
12 <div id="console"></div>
13 <script>
14 description("This test makes sure menu lists fire events on both the option that lost selection and the one that gained selection.");
15 window.jsTestIsAsync = true;
16
17 if (window.testRunner && window.accessibilityController) {
18 window.testRunner.dumpAsText();
19
20 var menulist = document.getElementById("menulist");
21 menulist.selectedIndex = 0;
22
23 var axMenuList = accessibilityController.accessibleElementById("menulist");
24 var axMenuListPopup = axMenuList.childAtIndex(0);
25 shouldBe("axMenuListPopup.role", "\"AXRole: AXMenuListPopup\"");
26 var axMenuListOption = axMenuListPopup.childAtIndex(0);
27 shouldBe("axMenuListOption.role", "\"AXRole: AXMenuListOption\"");
28
29 window.setTimeout(function() {
30
31 // Explore the whole accessibility tree. State change events won't fire on a ccessible objects that haven't
32 // been created yet.
33 accessibilityController.accessibleElementById('foo');
34
35 accessibilityController.addNotificationListener(function(element, notificati on) {
36 if (element.stringValue == axMenuListOption.stringValue) {
37 window.element = element;
38 shouldBe("element.isEqual(axMenuListOption)", "true");
39 shouldBe("element.parentElement().isEqual(axMenuListPopup)", "true") ;
40 finishJSTest();
41 }
42 });
43
44 menulist.selectedIndex = 1;
45 }, 0);
46 }
47
48 </script>
49
50 </body>
51 </html>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/accessibility/menu-list-popup-reuses-objects-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698