Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / events / frame-detached-in-mousedown.html
blobdc6089f64d2e91dbfdda5ac76434635a68189a0f
1 <html>
2 <body onload="startTest()">
3 <p>Test for <a href="https://bugs.webkit.org/show_bug.cgi?id=18595">bug 18595</a>:
4 Setting display:none on an iframe causes the ownerDocument to freeze.</p>
5 <div id="log">Please do what links below say:</div>
6 <a id=foo href="javascript:pass()"></a>
7 <iframe src="about:blank"></iframe>
8 <script>
9 if (window.testRunner) {
10 testRunner.waitUntilDone();
11 testRunner.dumpAsText();
14 var iframe = document.getElementsByTagName("iframe")[0];
16 function startTest()
18 var doc = iframe.contentDocument;
19 var a = doc.createElement('a');
20 a.href='#';
21 a.onmousedown=function(){
22 document.getElementById('foo').appendChild(document.createTextNode('Now click me'));
23 iframe.style.display='none';
25 a.appendChild(document.createTextNode('Click me'));
26 doc.body.appendChild(a);
28 if (window.eventSender) {
29 var x = iframe.offsetLeft + a.offsetLeft + 7;
30 var y = iframe.offsetTop + a.offsetTop + 7;
31 eventSender.mouseMoveTo(x, y);
32 eventSender.mouseDown();
33 eventSender.mouseUp();
34 setTimeout(click2, 10);
38 function click2()
40 var foo = document.getElementById("foo");
41 var x = foo.offsetLeft + 7;
42 var y = foo.offsetTop + 7;
43 eventSender.mouseMoveTo(x, y);
44 eventSender.mouseDown();
45 eventSender.mouseUp();
48 function pass()
50 document.getElementById("log").innerHTML = "PASS";
51 document.getElementById("foo").innerHTML = "";
53 if (window.testRunner)
54 testRunner.notifyDone();
57 </script>
58 </body>
59 </html>