| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved. | 4 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved. |
| 5 * | 5 * |
| 6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
| 7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
| 8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
| 9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
| 10 * | 10 * |
| (...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 195 explicit LayoutBox(ContainerNode*); | 195 explicit LayoutBox(ContainerNode*); |
| 196 | 196 |
| 197 PaintLayerType layerTypeRequired() const override; | 197 PaintLayerType layerTypeRequired() const override; |
| 198 | 198 |
| 199 bool backgroundIsKnownToBeOpaqueInRect(const LayoutRect& localRect) const ov
erride; | 199 bool backgroundIsKnownToBeOpaqueInRect(const LayoutRect& localRect) const ov
erride; |
| 200 | 200 |
| 201 virtual bool backgroundShouldAlwaysBeClipped() const { return false; } | 201 virtual bool backgroundShouldAlwaysBeClipped() const { return false; } |
| 202 | 202 |
| 203 // Use this with caution! No type checking is done! | 203 // Use this with caution! No type checking is done! |
| 204 LayoutBox* firstChildBox() const; | 204 LayoutBox* firstChildBox() const; |
| 205 LayoutBox* firstInFlowChildBox() const; | |
| 206 LayoutBox* lastChildBox() const; | 205 LayoutBox* lastChildBox() const; |
| 207 | 206 |
| 208 int pixelSnappedWidth() const { return m_frameRect.pixelSnappedWidth(); } | 207 int pixelSnappedWidth() const { return m_frameRect.pixelSnappedWidth(); } |
| 209 int pixelSnappedHeight() const { return m_frameRect.pixelSnappedHeight(); } | 208 int pixelSnappedHeight() const { return m_frameRect.pixelSnappedHeight(); } |
| 210 | 209 |
| 211 void setX(LayoutUnit x) | 210 void setX(LayoutUnit x) |
| 212 { | 211 { |
| 213 if (x == m_frameRect.x()) | 212 if (x == m_frameRect.x()) |
| 214 return; | 213 return; |
| 215 m_frameRect.setX(x); | 214 m_frameRect.setX(x); |
| (...skipping 952 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1168 inline LayoutBox* LayoutBox::parentBox() const | 1167 inline LayoutBox* LayoutBox::parentBox() const |
| 1169 { | 1168 { |
| 1170 return toLayoutBox(parent()); | 1169 return toLayoutBox(parent()); |
| 1171 } | 1170 } |
| 1172 | 1171 |
| 1173 inline LayoutBox* LayoutBox::firstChildBox() const | 1172 inline LayoutBox* LayoutBox::firstChildBox() const |
| 1174 { | 1173 { |
| 1175 return toLayoutBox(slowFirstChild()); | 1174 return toLayoutBox(slowFirstChild()); |
| 1176 } | 1175 } |
| 1177 | 1176 |
| 1178 inline LayoutBox* LayoutBox::firstInFlowChildBox() const | |
| 1179 { | |
| 1180 LayoutBox* child = firstChildBox(); | |
| 1181 while (child && child->isOutOfFlowPositioned()) | |
| 1182 child = child->nextSiblingBox(); | |
| 1183 return child; | |
| 1184 } | |
| 1185 | |
| 1186 inline LayoutBox* LayoutBox::lastChildBox() const | 1177 inline LayoutBox* LayoutBox::lastChildBox() const |
| 1187 { | 1178 { |
| 1188 return toLayoutBox(slowLastChild()); | 1179 return toLayoutBox(slowLastChild()); |
| 1189 } | 1180 } |
| 1190 | 1181 |
| 1191 inline LayoutBox* LayoutBox::previousSiblingMultiColumnBox() const | 1182 inline LayoutBox* LayoutBox::previousSiblingMultiColumnBox() const |
| 1192 { | 1183 { |
| 1193 ASSERT(isLayoutMultiColumnSpannerPlaceholder() || isLayoutMultiColumnSet()); | 1184 ASSERT(isLayoutMultiColumnSpannerPlaceholder() || isLayoutMultiColumnSet()); |
| 1194 LayoutBox* previousBox = previousSiblingBox(); | 1185 LayoutBox* previousBox = previousSiblingBox(); |
| 1195 if (previousBox->isLayoutFlowThread()) | 1186 if (previousBox->isLayoutFlowThread()) |
| (...skipping 28 matching lines...) Expand all Loading... |
| 1224 || breakValue == BreakLeft | 1215 || breakValue == BreakLeft |
| 1225 || breakValue == BreakPage | 1216 || breakValue == BreakPage |
| 1226 || breakValue == BreakRecto | 1217 || breakValue == BreakRecto |
| 1227 || breakValue == BreakRight | 1218 || breakValue == BreakRight |
| 1228 || breakValue == BreakVerso; | 1219 || breakValue == BreakVerso; |
| 1229 } | 1220 } |
| 1230 | 1221 |
| 1231 } // namespace blink | 1222 } // namespace blink |
| 1232 | 1223 |
| 1233 #endif // LayoutBox_h | 1224 #endif // LayoutBox_h |
| OLD | NEW |