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

Side by Side Diff: third_party/WebKit/LayoutTests/fragmentation/table-row-with-specified-height.html

Issue 2434543004: Specified row height should be applied during initial section layout. (Closed)
Patch Set: Code review. Created 4 years, 2 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/layout/LayoutTableSection.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <div id="multicol" style="columns:3; column-fill:auto; column-gap:0; height:90px ; line-height:20px;">
3 <br>
4 <br>
5 <table cellspacing="0" cellpadding="0">
6 <tr style="height:50px;">
7 <td><br></td>
8 </tr>
9 <tr id="secondRow" style="height:61px; background:blue;">
10 <td id="secondCell"><div style="width:61px;"><br></div></td>
11 </tr>
12 <tr>
13 <td><br></td>
14 </tr>
15 </table>
16 </div>
17
18 <script src="../resources/testharness.js"></script>
19 <script src="../resources/testharnessreport.js"></script>
20 <script>
21 var multicol = document.getElementById("multicol");
22 var row = document.getElementById("secondRow");
23 var cell = document.getElementById("secondCell");
24
25 // Check the height of the second row and its cell a few times, with a
26 // layout pass between each check, to verify that it's stable.
27
28 test(() => {
29 assert_equals(cell.offsetTop, 50);
30 assert_equals(cell.offsetHeight, 61);
31 assert_equals(row.offsetTop, 50);
32 assert_equals(row.offsetHeight, 61);
33 }, "Row height should be as specified.");
34
35 test(() => {
36 // Change width and verify that layout remains the same, block direction -wise.
37 multicol.style.width = "500px";
38
39 assert_equals(cell.offsetTop, 50);
40 assert_equals(cell.offsetHeight, 61);
41 assert_equals(row.offsetTop, 50);
42 assert_equals(row.offsetHeight, 61);
43
44 }, "Row height should be as specified after relayout.");
45
46 test(() => {
47 // Change width and verify that layout remains the same, block direction -wise.
48 multicol.style.width = "550px";
49
50 assert_equals(cell.offsetTop, 50);
51 assert_equals(cell.offsetHeight, 61);
52 assert_equals(row.offsetTop, 50);
53 assert_equals(row.offsetHeight, 61);
54
55 }, "Row height should be as specified after another relayout.");
56
57 test(() => {
58 // Change width and verify that layout remains the same, block direction -wise.
59 multicol.style.width = "600px";
60
61 assert_equals(cell.offsetTop, 50);
62 assert_equals(cell.offsetHeight, 61);
63 assert_equals(row.offsetTop, 50);
64 assert_equals(row.offsetHeight, 61);
65
66 }, "Row height should be as specified after yet another relayout.");
67 </script>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/layout/LayoutTableSection.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698