Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(396)

Side by Side Diff: LayoutTests/fast/dom/beforeload/pi-before-load.xhtml

Issue 205523003: Remove beforeload events. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Remove more tests Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 <?xml version="1.0" encoding="UTF-8"?>
2 <html xmlns="http://www.w3.org/1999/xhtml">
3 <head>
4 <style>
5 .block {
6 width: 100px;
7 height: 100px;
8 background-color: green;
9 }
10 </style>
11 <script src="resources/print.js"></script>
12 <script>
13 function test()
14 {
15 if (window.testRunner)
16 testRunner.dumpAsText();
17
18 if (document.getElementById('block').offsetWidth == 100)
19 print("PASS", "green");
20 else
21 print("FAIL", "red");
22 }
23 </script>
24 </head>
25 <body onload="test()">
26 <div id="block" class="block"></div>
27 <script>
28 function beforeLoadFunc()
29 {
30 event.preventDefault();
31 }
32
33 document.addEventListener("beforeload", beforeLoadFunc, true);
34
35 var pi = document.createProcessingInstruction("xml-stylesheet", "type=\"text/css \" href=\"resources/fail.css\"");
36 document.insertBefore(pi, document.documentElement);
37 </script>
38 <hr/>
39 <div id="console"></div>
40 </body>
41 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698