Thu, 15 Jan 2015 21:03:48 +0100
Integrate friendly tips from Tor colleagues to make (or not) 4.5 alpha 3;
This includes removal of overloaded (but unused) methods, and addition of
a overlooked call to DataStruct::SetData(nsISupports, uint32_t, bool.)
1 <html>
2 <head>
3 <title>Synchronized document.load() test</title>
4 <style type="text/css">
5 .box {
6 display: box;
7 border: 1px solid black;
8 margin-bottom: 0.5em;
9 }
10 .boxheader {
11 font-weight: bold;
12 color: maroon;
13 }
14 pre {
15 margin-left: 2em;
16 }
17 </style>
18 <script type="text/javascript">
19 var xmlDoc = document.implementation.createDocument("", "test", null);
21 function documentLoaded(e) {
22 var s = new XMLSerializer();
23 var str = s.serializeToString(xmlDoc);
24 document.getElementById("id1").firstChild.nodeValue = str;
25 var eventProperties = "";
26 for (prop in e) {
27 eventProperties += prop + " : '" + e[prop] + "'\n";
28 }
29 document.getElementById("id2").firstChild.nodeValue =
30 "Event object: " + e + "\n" +
31 "Event properties:\n" +
32 eventProperties;
33 }
35 xmlDoc.addEventListener("load", documentLoaded, false);
37 function execute()
38 {
39 xmlDoc.load("test.xml");
40 }
42 </script>
43 </head>
44 <body onload="execute();">
45 <h1>Synchronized document.load() test</h1>
47 <div class="box"><span class="boxheader">XML document serialized</span>
48 <pre id="id1">@@No result@@</pre>
49 </div>
50 <div class="box"><span class="boxheader">Event information</span>
51 <pre id="id2">@@No result@@</pre>
52 </div>
54 </body>
55 </body>
56 </html>