| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2000 Antti Koivisto (koivisto@kde.org) | 3 * (C) 2000 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2000 Dirk Mueller (mueller@kde.org) | 4 * (C) 2000 Dirk Mueller (mueller@kde.org) |
| 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) | 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) |
| 6 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2012 Apple Inc. All r
ights reserved. | 6 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2012 Apple Inc. All r
ights reserved. |
| 7 * Copyright (C) 2009 Google Inc. All rights reserved. | 7 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 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 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 60 class RenderInline; | 60 class RenderInline; |
| 61 class RenderBlock; | 61 class RenderBlock; |
| 62 class RenderFlowThread; | 62 class RenderFlowThread; |
| 63 class RenderGeometryMap; | 63 class RenderGeometryMap; |
| 64 class RenderLayer; | 64 class RenderLayer; |
| 65 class RenderLayerModelObject; | 65 class RenderLayerModelObject; |
| 66 class RenderNamedFlowThread; | 66 class RenderNamedFlowThread; |
| 67 class RenderSVGResourceContainer; | 67 class RenderSVGResourceContainer; |
| 68 class RenderTable; | 68 class RenderTable; |
| 69 class RenderTheme; | 69 class RenderTheme; |
| 70 class RenderView; |
| 70 class TransformState; | 71 class TransformState; |
| 71 | 72 |
| 72 struct PaintInfo; | 73 struct PaintInfo; |
| 73 | 74 |
| 74 enum CursorDirective { | 75 enum CursorDirective { |
| 75 SetCursorBasedOnStyle, | 76 SetCursorBasedOnStyle, |
| 76 SetCursor, | 77 SetCursor, |
| 77 DoNotSetCursor | 78 DoNotSetCursor |
| 78 }; | 79 }; |
| 79 | 80 |
| (...skipping 590 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 670 | 671 |
| 671 // Recursive function that computes the size and position of this object and
all its descendants. | 672 // Recursive function that computes the size and position of this object and
all its descendants. |
| 672 virtual void layout(); | 673 virtual void layout(); |
| 673 | 674 |
| 674 /* This function performs a layout only if one is needed. */ | 675 /* This function performs a layout only if one is needed. */ |
| 675 void layoutIfNeeded() { if (needsLayout()) layout(); } | 676 void layoutIfNeeded() { if (needsLayout()) layout(); } |
| 676 | 677 |
| 677 void forceLayout(); | 678 void forceLayout(); |
| 678 void forceChildLayout(); | 679 void forceChildLayout(); |
| 679 | 680 |
| 681 // True if we can abort layout, leaving a partially laid out tree. |
| 682 virtual bool supportsPartialLayout() const { return false; } |
| 683 |
| 680 // used for element state updates that cannot be fixed with a | 684 // used for element state updates that cannot be fixed with a |
| 681 // repaint and do not need a relayout | 685 // repaint and do not need a relayout |
| 682 virtual void updateFromElement() { } | 686 virtual void updateFromElement() { } |
| 683 | 687 |
| 684 virtual void addAnnotatedRegions(Vector<AnnotatedRegionValue>&); | 688 virtual void addAnnotatedRegions(Vector<AnnotatedRegionValue>&); |
| 685 void collectAnnotatedRegions(Vector<AnnotatedRegionValue>&); | 689 void collectAnnotatedRegions(Vector<AnnotatedRegionValue>&); |
| 686 | 690 |
| 687 bool isComposited() const; | 691 bool isComposited() const; |
| 688 | 692 |
| 689 bool hitTest(const HitTestRequest&, HitTestResult&, const HitTestLocation& l
ocationInContainer, const LayoutPoint& accumulatedOffset, HitTestFilter = HitTes
tAll); | 693 bool hitTest(const HitTestRequest&, HitTestResult&, const HitTestLocation& l
ocationInContainer, const LayoutPoint& accumulatedOffset, HitTestFilter = HitTes
tAll); |
| (...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1069 StyleColor styleColor = color; | 1073 StyleColor styleColor = color; |
| 1070 for (const RenderObject* object = this; UNLIKELY(styleColor.isCurrentCol
or()) && object && object->style(); object = object->parent()) | 1074 for (const RenderObject* object = this; UNLIKELY(styleColor.isCurrentCol
or()) && object && object->style(); object = object->parent()) |
| 1071 styleColor = object->style()->visitedDependentColor(CSSPropertyColor
); | 1075 styleColor = object->style()->visitedDependentColor(CSSPropertyColor
); |
| 1072 return styleColor; | 1076 return styleColor; |
| 1073 } | 1077 } |
| 1074 | 1078 |
| 1075 void removeShapeImageClient(ShapeValue*); | 1079 void removeShapeImageClient(ShapeValue*); |
| 1076 | 1080 |
| 1077 #ifndef NDEBUG | 1081 #ifndef NDEBUG |
| 1078 void checkBlockPositionedObjectsNeedLayout(); | 1082 void checkBlockPositionedObjectsNeedLayout(); |
| 1083 void checkNotInPartialLayout(); |
| 1079 #endif | 1084 #endif |
| 1080 | 1085 |
| 1081 RefPtr<RenderStyle> m_style; | 1086 RefPtr<RenderStyle> m_style; |
| 1082 | 1087 |
| 1083 Node* m_node; | 1088 Node* m_node; |
| 1084 | 1089 |
| 1085 RenderObject* m_parent; | 1090 RenderObject* m_parent; |
| 1086 RenderObject* m_previous; | 1091 RenderObject* m_previous; |
| 1087 RenderObject* m_next; | 1092 RenderObject* m_next; |
| 1088 | 1093 |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1239 return true; | 1244 return true; |
| 1240 } | 1245 } |
| 1241 | 1246 |
| 1242 inline bool RenderObject::isBeforeOrAfterContent() const | 1247 inline bool RenderObject::isBeforeOrAfterContent() const |
| 1243 { | 1248 { |
| 1244 return isBeforeContent() || isAfterContent(); | 1249 return isBeforeContent() || isAfterContent(); |
| 1245 } | 1250 } |
| 1246 | 1251 |
| 1247 inline void RenderObject::setNeedsLayout(MarkingBehavior markParents, SubtreeLay
outScope* layouter) | 1252 inline void RenderObject::setNeedsLayout(MarkingBehavior markParents, SubtreeLay
outScope* layouter) |
| 1248 { | 1253 { |
| 1254 #ifndef NDEBUG |
| 1255 checkNotInPartialLayout(); |
| 1256 #endif |
| 1249 ASSERT(!isSetNeedsLayoutForbidden()); | 1257 ASSERT(!isSetNeedsLayoutForbidden()); |
| 1250 bool alreadyNeededLayout = m_bitfields.needsLayout(); | 1258 bool alreadyNeededLayout = m_bitfields.needsLayout(); |
| 1251 m_bitfields.setNeedsLayout(true); | 1259 m_bitfields.setNeedsLayout(true); |
| 1252 if (!alreadyNeededLayout) { | 1260 if (!alreadyNeededLayout) { |
| 1253 if (markParents == MarkContainingBlockChain && (!layouter || layouter->r
oot() != this)) | 1261 if (markParents == MarkContainingBlockChain && (!layouter || layouter->r
oot() != this)) |
| 1254 markContainingBlocksForLayout(true, 0, layouter); | 1262 markContainingBlocksForLayout(true, 0, layouter); |
| 1255 if (hasLayer()) | 1263 if (hasLayer()) |
| 1256 setLayerNeedsFullRepaint(); | 1264 setLayerNeedsFullRepaint(); |
| 1257 } | 1265 } |
| 1258 } | 1266 } |
| 1259 | 1267 |
| 1260 inline void RenderObject::clearNeedsLayout() | 1268 inline void RenderObject::clearNeedsLayout() |
| 1261 { | 1269 { |
| 1270 #ifndef NDEBUG |
| 1271 checkNotInPartialLayout(); |
| 1272 #endif |
| 1262 m_bitfields.setNeedsLayout(false); | 1273 m_bitfields.setNeedsLayout(false); |
| 1263 setEverHadLayout(true); | 1274 setEverHadLayout(true); |
| 1264 setPosChildNeedsLayout(false); | 1275 setPosChildNeedsLayout(false); |
| 1265 setNeedsSimplifiedNormalFlowLayout(false); | 1276 setNeedsSimplifiedNormalFlowLayout(false); |
| 1266 setNormalChildNeedsLayout(false); | 1277 setNormalChildNeedsLayout(false); |
| 1267 setNeedsPositionedMovementLayout(false); | 1278 setNeedsPositionedMovementLayout(false); |
| 1268 setAncestorLineBoxDirty(false); | 1279 setAncestorLineBoxDirty(false); |
| 1269 #ifndef NDEBUG | 1280 #ifndef NDEBUG |
| 1270 checkBlockPositionedObjectsNeedLayout(); | 1281 checkBlockPositionedObjectsNeedLayout(); |
| 1271 #endif | 1282 #endif |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1396 // Outside the WebCore namespace for ease of invocation from gdb. | 1407 // Outside the WebCore namespace for ease of invocation from gdb. |
| 1397 void showTree(const WebCore::RenderObject*); | 1408 void showTree(const WebCore::RenderObject*); |
| 1398 void showLineTree(const WebCore::RenderObject*); | 1409 void showLineTree(const WebCore::RenderObject*); |
| 1399 void showRenderTree(const WebCore::RenderObject* object1); | 1410 void showRenderTree(const WebCore::RenderObject* object1); |
| 1400 // We don't make object2 an optional parameter so that showRenderTree | 1411 // We don't make object2 an optional parameter so that showRenderTree |
| 1401 // can be called from gdb easily. | 1412 // can be called from gdb easily. |
| 1402 void showRenderTree(const WebCore::RenderObject* object1, const WebCore::RenderO
bject* object2); | 1413 void showRenderTree(const WebCore::RenderObject* object1, const WebCore::RenderO
bject* object2); |
| 1403 #endif | 1414 #endif |
| 1404 | 1415 |
| 1405 #endif // RenderObject_h | 1416 #endif // RenderObject_h |
| OLD | NEW |