Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / ManualTests / stale-currentEvent.html
blobe9dfcfc291f2708c503f3e31151a1a780515d029
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
2 "http://www.w3.org/TR/html4/strict.dtd">
3 <html lang="en">
4 <head>
5 <script type="text/javascript">
6 var inner_win;
8 function open_inner()
10 var src = 'data:text/html,<title>Pop up</title><input type="button" value="Close" onclick="opener.closeChild()">';
11 var tp = document.getElementById("theparent");
12 inner_win = window.open(src, 'inner', 'width=200, height=200, left=' + (screenLeft + tp.offsetLeft) + ', top=' + (screenTop + outerHeight - innerHeight + tp.offsetTop));
15 function removeHoverNode()
17 var tp = document.getElementById("theparent");
18 tp.parentNode.removeChild(tp);
19 setTimeout(reportSuccess, 500);
22 function reportSuccess()
24 document.body.appendChild(document.createTextNode("SUCCESS"));
27 function closeChild()
29 inner_win.close();
30 document.body.offsetTop;
31 setTimeout(removeHoverNode, 100);
33 </script>
34 </head>
35 <body>
36 <p><b>BUG ID:</b> <a href="rdar://problem/5095977">5095997</a> (<a href="http://bugs.webkit.org/show_bug.cgi?id=13218">13218</a>) Reproducible crash after call to window.close()</p>
38 <p id="test" style="background-color:skyblue; padding:3px;"><b>STEPS TO TEST:</b><br>
39 1. Click the Open button below. A pop up window will open.<br>
40 2. In the pop up window, click the Close button, being careful not to
41 move the mouse during and shortly after clicking.
42 </p>
44 <p id="success" style="background-color:palegreen; padding:3px;"><b>TEST PASS:</b>
45 The black square will be replaced by the word &ldquo;SUCCESS&rdquo; and Safari will not crash.
46 </p>
48 <p id="failure" style="background-color:#FF3300; padding:3px;"><b>TEST FAIL:</b>
49 Safari will crash (the word &ldquo;SUCCESS&rdquo; may appear before the crash).
50 </p>
51 <div id='theparent'>
52 <input type="button" value="Open" onclick="open_inner()">
53 <div style="background: black; width: 200px; height:200px">
54 </div>
55 </div>
56 </body>
57 </html>