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/Source/core/layout/LayoutMultiColumnSet.h

Issue 1471403002: Look inside inner nested multicols to calculate minimum space shortage. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2012 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 const MultiColumnFragmentainerGroup& lastFragmentainerGroup() const { return m_fragmentainerGroups.last(); } 66 const MultiColumnFragmentainerGroup& lastFragmentainerGroup() const { return m_fragmentainerGroups.last(); }
67 MultiColumnFragmentainerGroup& fragmentainerGroupAtFlowThreadOffset(LayoutUn it flowThreadOffset) 67 MultiColumnFragmentainerGroup& fragmentainerGroupAtFlowThreadOffset(LayoutUn it flowThreadOffset)
68 { 68 {
69 return m_fragmentainerGroups[fragmentainerGroupIndexAtFlowThreadOffset(f lowThreadOffset)]; 69 return m_fragmentainerGroups[fragmentainerGroupIndexAtFlowThreadOffset(f lowThreadOffset)];
70 } 70 }
71 const MultiColumnFragmentainerGroup& fragmentainerGroupAtFlowThreadOffset(La youtUnit flowThreadOffset) const 71 const MultiColumnFragmentainerGroup& fragmentainerGroupAtFlowThreadOffset(La youtUnit flowThreadOffset) const
72 { 72 {
73 return m_fragmentainerGroups[fragmentainerGroupIndexAtFlowThreadOffset(f lowThreadOffset)]; 73 return m_fragmentainerGroups[fragmentainerGroupIndexAtFlowThreadOffset(f lowThreadOffset)];
74 } 74 }
75 const MultiColumnFragmentainerGroup& fragmentainerGroupAtVisualPoint(const L ayoutPoint&) const; 75 const MultiColumnFragmentainerGroup& fragmentainerGroupAtVisualPoint(const L ayoutPoint&) const;
76 const MultiColumnFragmentainerGroupList& fragmentainerGroups() const { retur n m_fragmentainerGroups; }
76 77
77 bool isOfType(LayoutObjectType type) const override { return type == LayoutO bjectLayoutMultiColumnSet || LayoutBlockFlow::isOfType(type); } 78 bool isOfType(LayoutObjectType type) const override { return type == LayoutO bjectLayoutMultiColumnSet || LayoutBlockFlow::isOfType(type); }
78 bool canHaveChildren() const final { return false; } 79 bool canHaveChildren() const final { return false; }
79 80
80 // Return the width and height of a single column or page in the set. 81 // Return the width and height of a single column or page in the set.
81 LayoutUnit pageLogicalWidth() const { return flowThread()->logicalWidth(); } 82 LayoutUnit pageLogicalWidth() const { return flowThread()->logicalWidth(); }
82 LayoutUnit pageLogicalHeightForOffset(LayoutUnit) const; 83 LayoutUnit pageLogicalHeightForOffset(LayoutUnit) const;
83 LayoutUnit pageRemainingLogicalHeightForOffset(LayoutUnit, PageBoundaryRule) const; 84 LayoutUnit pageRemainingLogicalHeightForOffset(LayoutUnit, PageBoundaryRule) const;
84 bool isPageLogicalHeightKnown() const; 85 bool isPageLogicalHeightKnown() const;
85 LayoutUnit tallestUnbreakableLogicalHeight() const { return m_tallestUnbreak ableLogicalHeight; } 86 LayoutUnit tallestUnbreakableLogicalHeight() const { return m_tallestUnbreak ableLogicalHeight; }
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 // largest one among them. 180 // largest one among them.
180 LayoutUnit m_tallestUnbreakableLogicalHeight; 181 LayoutUnit m_tallestUnbreakableLogicalHeight;
181 }; 182 };
182 183
183 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutMultiColumnSet, isLayoutMultiColumnSet()); 184 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutMultiColumnSet, isLayoutMultiColumnSet());
184 185
185 } // namespace blink 186 } // namespace blink
186 187
187 #endif // LayoutMultiColumnSet_h 188 #endif // LayoutMultiColumnSet_h
188 189
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698