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

Side by Side Diff: LayoutTests/fast/frames/frame-dimensions-before-parent-layout.html

Issue 19272007: Update parent layout when child frame requests innerHeight/innerWidth. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Only force layout in innerWidth/innerHeight Created 7 years, 5 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 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2 <html>
3 <head>
4 <script src="../js/resources/js-test-pre.js"></script>
5 </head>
6 <body>
7 <script>
8 description('Tests that querying dimensions in an iframe returns the correct val ue even before the parent frame has had a layout');
9
10 var iframe = document.createElement('iframe');
11 document.body.appendChild(iframe);
12
13 var heightBeforeLayout = iframe.contentWindow.innerHeight;
14 var forceLayout = iframe.offsetHeight;
15 var heightAfterLayout = iframe.contentWindow.innerHeight;
16
17 shouldBe('heightBeforeLayout', 'heightAfterLayout');
18
19 var iframe2 = document.createElement('iframe');
20 document.body.appendChild(iframe2);
21
22 var widthBeforeLayout = iframe2.contentWindow.innerWidth;
23 var forceLayout = iframe2.offsetHeight;
24 var widthAfterLayout = iframe2.contentWindow.innerWidth;
25
26 shouldBe('widthBeforeLayout', 'widthAfterLayout');
27 </script>
28 <script src="../js/resources/js-test-post.js"></script>
29 </body>
30 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698