OLD | NEW |
1 <!-- Based on fast/repaint/selection-change-in-iframe-with-relative-parent.html
--> | 1 <!-- Based on fast/repaint/selection-change-in-iframe-with-relative-parent.html
--> |
2 <!DOCTYPE html> | 2 <!DOCTYPE html> |
3 <style> | 3 <style> |
4 .container { | 4 .container { |
5 position: relative; | 5 position: relative; |
6 top: 180px; | 6 top: 180px; |
7 } | 7 } |
8 </style> | 8 </style> |
9 | 9 |
10 <!-- | 10 <!-- |
11 This test checks that the selection in an iframe in a relative positioned co
ntainer | 11 This test checks that the selection in an iframe in a relative positioned co
ntainer |
12 is correctly invalidated. | 12 is correctly invalidated. |
13 We should be able to manually select all the text. The invalidation rects sh
ould | 13 We should be able to manually select all the text. The invalidation rects sh
ould |
14 be positioned correctly and encompass all the lines. | 14 be positioned correctly and encompass all the lines. |
15 --> | 15 --> |
16 <div class="container"> | 16 <div class="container"> |
17 <iframe src="../../../fast/repaint/resources/selection-change-in-iframe-with
-relative-parent-iframe.html"></iframe> | 17 <iframe src="../../../fast/repaint/resources/selection-change-in-iframe-with
-relative-parent-iframe.html"></iframe> |
18 </div> | 18 </div> |
19 | 19 |
20 <script src="resources/paint-invalidation-test.js" type="text/javascript"></scri
pt> | 20 <script src="resources/paint-invalidation-test.js" type="text/javascript"></scri
pt> |
21 <script> | 21 <script> |
22 if (window.testRunner) | |
23 testRunner.dumpAsTextWithPixelResults(); | |
24 | |
25 window.expectedPaintInvalidationObjects = [ | |
26 "LayoutBlockFlow HTML", | |
27 "LayoutBlockFlow BODY", | |
28 "LayoutText #text", | |
29 "InlineTextBox 'Foo'", | |
30 "LayoutBR BR", | |
31 "InlineTextBox '\n'", | |
32 "LayoutBR BR", | |
33 "InlineTextBox '\n'", | |
34 "LayoutText #text", | |
35 "InlineTextBox 'Bar'", | |
36 "LayoutBR BR", | |
37 "InlineTextBox '\n'", | |
38 "LayoutBR BR", | |
39 "InlineTextBox '\n'", | |
40 "LayoutText #text", | |
41 "InlineTextBox 'Bazz'", | |
42 "LayoutBR BR", | |
43 "InlineTextBox '\n'", | |
44 ]; | |
45 function paintInvalidationTest() | 22 function paintInvalidationTest() |
46 { | 23 { |
47 var iframe = document.getElementsByTagName("iframe")[0]; | 24 var iframe = document.getElementsByTagName("iframe")[0]; |
48 iframe.contentWindow.getSelection().selectAllChildren(iframe.contentDocument
.body); | 25 iframe.contentWindow.getSelection().selectAllChildren(iframe.contentDocument
.body); |
49 } | 26 } |
50 window.addEventListener("load", runPaintInvalidationTest, false); | 27 window.addEventListener("load", runPaintInvalidationTest, false); |
51 </script> | 28 </script> |
OLD | NEW |