Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / repaint / selection-clear.html
blob3ad8551c25dd7285d004b1f8969db73d937ff119
1 <html>
2 <head>
3 <script src="resources/text-based-repaint.js" type="text/javascript"></script>
4 <script type="text/javascript">
5 function repaintTest()
7 firstLine.appendChild(document.createTextNode("\u00a0"));
8 firstLine.removeChild(firstLine.firstChild);
10 </script>
11 <style>
12 #firstLine { background-color: green; }
13 #firstLine::selection { background-color: green; }
14 </style>
15 </head>
16 <body onload="runRepaintTest();">
17 <div id="root" style="width: 100px; line-height: 100px;">
18 <div id="firstLine">FAIL: Test did not run</div><br>
19 </div>
20 <script>
21 var root = document.getElementById("root");
22 var firstLine = document.getElementById("firstLine");
23 var selection = getSelection();
25 selection.setBaseAndExtent(firstLine, 0, root.lastChild, 0);
26 </script>
27 </body>