<html>
<head>
<script>
function test()
{
if (window.testRunner)
testRunner.dumpAsText();
log(document.activeElement);
document.getElementById('one').focus();
log(document.activeElement + " id: " + document.activeElement.id);
document.getElementById('two').focus();
log(document.activeElement + " id: " + document.activeElement.id);
document.getElementById('two').blur();
log(document.activeElement);
}
function log(msg)
{
document.getElementById("console").appendChild(document.createTextNode(msg + "\n"));
}
</script>
</head>
<body onload="test()">
<input id="one"><input id="two">
<br>
<pre id="console"></pre>
</body>
</html>