blob: ce78fbdcd601fc64fc9c944a867901ff7159eff1 [file] [log] [blame] [edit]
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<script src="../resources/js-test-pre.js"></script>
</head>
<body id="body">
<input type="text" aria-disabled="true" size=20>
<input type="text" aria-disabled="false" size=20>
<p id="description"></p>
<div id="console"></div>
<script>
description("This tests that the aria-disabled attribute works. The text field should not be enabled.");
if (window.accessibilityController) {
var body = document.getElementById("body");
body.focus();
var textField;
if (accessibilityController.platformName === "atspi" || accessibilityController.platformName === "win")
textField = accessibilityController.focusedElement.childAtIndex(0).childAtIndex(0);
else
textField = accessibilityController.focusedElement.childAtIndex(0);
var succeeded = textField.isEnabled;
shouldBe("succeeded", "false");
if (accessibilityController.platformName === "atspi" || accessibilityController.platformName === "win")
textField = accessibilityController.focusedElement.childAtIndex(0).childAtIndex(1);
else
textField = accessibilityController.focusedElement.childAtIndex(1);
succeeded = textField.isEnabled;
shouldBe("succeeded", "true");
}
</script>
<script src="../resources/js-test-post.js"></script>
</body>
</html>