| Index: LayoutTests/fast/frames/take-focus-from-iframe.html
|
| ===================================================================
|
| --- LayoutTests/fast/frames/take-focus-from-iframe.html (revision 0)
|
| +++ LayoutTests/fast/frames/take-focus-from-iframe.html (revision 48064)
|
| @@ -0,0 +1,33 @@
|
| +<body onload="test()">
|
| +<iframe src="data:text/html,<body><input><script>document.getElementsByTagName('input')[0].focus()</script></body>" height=40 width=200></iframe>
|
| +<p>This field should look and act focused. Try to type into it: <input></p>
|
| +<script>
|
| +if (window.layoutTestController)
|
| + layoutTestController.waitUntilDone();
|
| +
|
| +function test()
|
| +{
|
| + document.getElementsByTagName("iframe")[0].focus();
|
| + frames[0].focus();
|
| + setTimeout('test2()', 10);
|
| +}
|
| +
|
| +function test2()
|
| +{
|
| + focus();
|
| + document.getElementsByTagName("input")[0].focus()
|
| +
|
| + if (window.eventSender) {
|
| + eventSender.keyDown('A');
|
| +
|
| + var input = document.getElementsByTagName("input")[0];
|
| + if (input.value == "A")
|
| + input.value = "PASS";
|
| + }
|
| +
|
| + if (window.layoutTestController)
|
| + layoutTestController.notifyDone();
|
| +
|
| +}
|
| +</script>
|
| +</body>
|
|
|