OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1997 Martin Jones (mjones@kde.org) | 2 * Copyright (C) 1997 Martin Jones (mjones@kde.org) |
3 * (C) 1997 Torben Weis (weis@kde.org) | 3 * (C) 1997 Torben Weis (weis@kde.org) |
4 * (C) 1998 Waldo Bastian (bastian@kde.org) | 4 * (C) 1998 Waldo Bastian (bastian@kde.org) |
5 * (C) 1999 Lars Knoll (knoll@kde.org) | 5 * (C) 1999 Lars Knoll (knoll@kde.org) |
6 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 6 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
7 * Copyright (C) 2003, 2004, 2005, 2006, 2009, 2013 Apple Inc. All rights reserv
ed. | 7 * Copyright (C) 2003, 2004, 2005, 2006, 2009, 2013 Apple Inc. All rights reserv
ed. |
8 * | 8 * |
9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
121 const BorderValue& borderAdjoiningEndCell(const LayoutTableCell*) const; | 121 const BorderValue& borderAdjoiningEndCell(const LayoutTableCell*) const; |
122 | 122 |
123 bool nodeAtPoint(HitTestResult&, const HitTestLocation& locationInContainer,
const LayoutPoint& accumulatedOffset, HitTestAction) override; | 123 bool nodeAtPoint(HitTestResult&, const HitTestLocation& locationInContainer,
const LayoutPoint& accumulatedOffset, HitTestAction) override; |
124 | 124 |
125 void addOverflowFromCell(const LayoutTableCell*); | 125 void addOverflowFromCell(const LayoutTableCell*); |
126 | 126 |
127 const char* name() const override { return "LayoutTableRow"; } | 127 const char* name() const override { return "LayoutTableRow"; } |
128 | 128 |
129 bool backgroundIsKnownToBeOpaqueInRect(const LayoutRect&) const override; | 129 bool backgroundIsKnownToBeOpaqueInRect(const LayoutRect&) const override; |
130 | 130 |
| 131 int paginationStrutPropagatedFromCell() const { return m_paginationStrutProp
agatedFromCell; } |
| 132 void resetPaginationStrutPropagatedFromCell() { m_paginationStrutPropagatedF
romCell = 0; } |
| 133 void setPaginationStrutPropagatedFromCell(LayoutUnit strut) { ASSERT(!m_pagi
nationStrutPropagatedFromCell || !strut || m_paginationStrutPropagatedFromCell =
= strut); m_paginationStrutPropagatedFromCell = strut; } |
| 134 |
131 private: | 135 private: |
132 LayoutObjectChildList* virtualChildren() override { return children(); } | 136 LayoutObjectChildList* virtualChildren() override { return children(); } |
133 const LayoutObjectChildList* virtualChildren() const override { return child
ren(); } | 137 const LayoutObjectChildList* virtualChildren() const override { return child
ren(); } |
134 | 138 |
135 bool isOfType(LayoutObjectType type) const override { return type == LayoutO
bjectTableRow || LayoutBox::isOfType(type); } | 139 bool isOfType(LayoutObjectType type) const override { return type == LayoutO
bjectTableRow || LayoutBox::isOfType(type); } |
136 | 140 |
137 void willBeRemovedFromTree() override; | 141 void willBeRemovedFromTree() override; |
138 | 142 |
139 void addChild(LayoutObject* child, LayoutObject* beforeChild = nullptr) over
ride; | 143 void addChild(LayoutObject* child, LayoutObject* beforeChild = nullptr) over
ride; |
140 void layout() override; | 144 void layout() override; |
(...skipping 17 matching lines...) Expand all Loading... |
158 | 162 |
159 void nextSibling() const = delete; | 163 void nextSibling() const = delete; |
160 void previousSibling() const = delete; | 164 void previousSibling() const = delete; |
161 | 165 |
162 LayoutObjectChildList m_children; | 166 LayoutObjectChildList m_children; |
163 | 167 |
164 // This field should never be read directly. It should be read through | 168 // This field should never be read directly. It should be read through |
165 // rowIndex() above instead. This is to ensure that we never read this | 169 // rowIndex() above instead. This is to ensure that we never read this |
166 // value before it is set. | 170 // value before it is set. |
167 unsigned m_rowIndex : 31; | 171 unsigned m_rowIndex : 31; |
| 172 int m_paginationStrutPropagatedFromCell; |
168 }; | 173 }; |
169 | 174 |
170 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutTableRow, isTableRow()); | 175 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutTableRow, isTableRow()); |
171 | 176 |
172 inline LayoutTableRow* LayoutTableRow::previousRow() const | 177 inline LayoutTableRow* LayoutTableRow::previousRow() const |
173 { | 178 { |
174 return toLayoutTableRow(LayoutObject::previousSibling()); | 179 return toLayoutTableRow(LayoutObject::previousSibling()); |
175 } | 180 } |
176 | 181 |
177 inline LayoutTableRow* LayoutTableRow::nextRow() const | 182 inline LayoutTableRow* LayoutTableRow::nextRow() const |
178 { | 183 { |
179 return toLayoutTableRow(LayoutObject::nextSibling()); | 184 return toLayoutTableRow(LayoutObject::nextSibling()); |
180 } | 185 } |
181 | 186 |
182 inline LayoutTableRow* LayoutTableSection::firstRow() const | 187 inline LayoutTableRow* LayoutTableSection::firstRow() const |
183 { | 188 { |
184 ASSERT(children() == virtualChildren()); | 189 ASSERT(children() == virtualChildren()); |
185 return toLayoutTableRow(children()->firstChild()); | 190 return toLayoutTableRow(children()->firstChild()); |
186 } | 191 } |
187 | 192 |
188 inline LayoutTableRow* LayoutTableSection::lastRow() const | 193 inline LayoutTableRow* LayoutTableSection::lastRow() const |
189 { | 194 { |
190 ASSERT(children() == virtualChildren()); | 195 ASSERT(children() == virtualChildren()); |
191 return toLayoutTableRow(children()->lastChild()); | 196 return toLayoutTableRow(children()->lastChild()); |
192 } | 197 } |
193 | 198 |
194 } // namespace blink | 199 } // namespace blink |
195 | 200 |
196 #endif // LayoutTableRow_h | 201 #endif // LayoutTableRow_h |
OLD | NEW |