blob: 31f9789bcb2d9980d842c359069b242ed1ee23df [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="editable" contenteditable="true">
<input id="input" type="text"></input>
</div>
<p id="description"></p>
<div id="console"></div>
<script>
description("This tests attributes for looking up editable and focusable ancestors.");
var input = 0;
var editable = 0;
var focusableAncestor = 0;
var editableAncestor = 0;
var highestAncestor = 0;
if (window.accessibilityController) {
accessibilityController.enableEnhancedAccessibility(true);
editable = accessibilityController.accessibleElementById("editable");
input = accessibilityController.accessibleElementById("input");
focusableAncestor = input.uiElementAttributeValue("AXFocusableAncestor");
editableAncestor = input.uiElementAttributeValue("AXEditableAncestor");
highestAncestor = input.uiElementAttributeValue("AXHighestEditableAncestor");
shouldBe("input.isEqual(focusableAncestor)", "true");
shouldBe("input.isEqual(editableAncestor)", "true");
shouldBe("editable.isEqual(highestAncestor)", "true");
}
</script>
<script src="../../resources/js-test-post.js"></script>
</body>
</html>