layout/reftests/table-anonymous-boxes/315146-1.xhtml

Fri, 16 Jan 2015 18:13:44 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Fri, 16 Jan 2015 18:13:44 +0100
branch
TOR_BUG_9701
changeset 14
925c144e1f1f
permissions
-rw-r--r--

Integrate suggestion from review to improve consistency with existing code.

     1 <?xml version="1.0" encoding="UTF-8"?>
     2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
     3 	"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
     4 <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en" class="reftest-wait">
     5 <head>
     6 	<script type="text/javascript"><![CDATA[
     7 	function DeleteRow(container) {
     8 		if (container.firstChild)
     9 			container.removeChild(container.firstChild);
    10 	}
    12 	function AddRow(container) {
    13 		var tr = document.createElement("tr");
    14 		var td = document.createElement("td");
    15 		td.appendChild(document.createTextNode("A cell"));
    16 		tr.appendChild(td);
    17 		container.appendChild(tr);
    18 	}
    20         function doTest() {
    21           for (var i = 0; i < 10; ++i) {
    22             document.body.offsetWidth;
    23             AddRow(document.getElementById('table'));
    24             document.body.offsetWidth;
    25             DeleteRow(document.getElementById('table'));
    26           }
    27           document.documentElement.className = '';
    28         }
    29 	]]></script>
    30 </head>
    31 <body onload="doTest()">
    32 <table id="table" border="5"><tr><td>A cell</td></tr></table>
    33 </body>
    34 </html>

mercurial