33 lines
889 B
HTML
33 lines
889 B
HTML
<html>
|
|
<head>
|
|
<script>
|
|
function log(message)
|
|
{
|
|
var item = document.createElement("li");
|
|
item.appendChild(document.createTextNode(message));
|
|
document.getElementById("console").appendChild(item);
|
|
}
|
|
function test()
|
|
{
|
|
if (window.testRunner) {
|
|
testRunner.dumpAsText();
|
|
|
|
if (navigator.userAgent.search(/\bMac OS X\b/) != -1)
|
|
modifiers = ["ctrlKey", "altKey"];
|
|
else
|
|
modifiers = "altKey";
|
|
eventSender.keyDown("f", modifiers);
|
|
}
|
|
}
|
|
</script>
|
|
</head>
|
|
<body onload="test()">
|
|
<p>This test checks to see if accesskey attributes work on legend elements.</p>
|
|
<p>If the test passes, you should see one line saying "focused" and the text field should have focus.</p>
|
|
<hr>
|
|
<p><fieldset><legend accesskey="f">Information:</legend><input onfocus="log('focused')" type="text"></fieldset><p>
|
|
<hr>
|
|
<ol id="console"></ol>
|
|
</body>
|
|
</html>
|