blob: d1d03c16e1705eebea8b86d0cfb99dfb2657170b [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<script src="../../resources/js-test-pre.js"></script>
</head>
<body id="body">
<div id="menu" role="menu">
<div role="menuitemcheckbox" id="menuitem1" aria-checked="true">test</div>
<div role="menuitemcheckbox" id="menuitem2" aria-checked="false">test</div>
<div role="menuitemradio" id="menuitem3" aria-checked="true">test</div>
<div role="menuitemradio" id="menuitem4" aria-checked="false">test</div>
</div>
<p id="description"></p>
<div id="console"></div>
<script>
description("This tests that the right Mac attribute for conveying 'checked' states works on menu items");
if (window.accessibilityController) {
var item1 = accessibilityController.accessibleElementById("menuitem1");
debug("Item 1 Mark: " + item1.stringAttributeValue('AXMenuItemMarkChar'));
var item2 = accessibilityController.accessibleElementById("menuitem2");
var item2mark = item2.stringAttributeValue('AXMenuItemMarkChar');
shouldBeTrue("!item2mark || item2mark == ''");
var item3 = accessibilityController.accessibleElementById("menuitem3");
debug("Item 3 Mark: " + item3.stringAttributeValue('AXMenuItemMarkChar'));
var item4 = accessibilityController.accessibleElementById("menuitem4");
var item4mark = item4.stringAttributeValue('AXMenuItemMarkChar');
shouldBeTrue("!item4mark || item4mark == ''");
document.getElementById("menu").style.visibility = "hidden";
}
</script>
<script src="../../resources/js-test-post.js"></script>
</body>
</html>