Changeset 156816 in webkit for trunk/Source/WebCore/rendering/RenderObject.h
- Timestamp:
- Oct 2, 2013, 7:26:52 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/rendering/RenderObject.h
r156738 r156816 618 618 619 619 void markContainingBlocksForLayout(bool scheduleRelayout = true, RenderObject* newRoot = 0); 620 void setNeedsLayout(bool needsLayout, MarkingBehavior = MarkContainingBlockChain); 621 void setChildNeedsLayout(bool childNeedsLayout, MarkingBehavior = MarkContainingBlockChain); 622 void setNeedsPositionedMovementLayout(const RenderStyle* oldStyle); 623 void setNeedsSimplifiedNormalFlowLayout(); 620 void setNeedsLayout(MarkingBehavior = MarkContainingBlockChain); 621 void clearNeedsLayout(); 624 622 void setPreferredLogicalWidthsDirty(bool, MarkingBehavior = MarkContainingBlockChain); 625 623 void invalidateContainerPreferredLogicalWidths(); … … 627 625 void setNeedsLayoutAndPrefWidthsRecalc() 628 626 { 629 setNeedsLayout( true);627 setNeedsLayout(); 630 628 setPreferredLogicalWidthsDirty(true); 631 629 } … … 941 939 942 940 void setDocumentForAnonymous(Document& document) { ASSERT(isAnonymous()); m_node = &document; } 941 942 void setNeedsPositionedMovementLayoutBit(bool b) { m_bitfields.setNeedsPositionedMovementLayout(b); } 943 void setNormalChildNeedsLayoutBit(bool b) { m_bitfields.setNormalChildNeedsLayout(b); } 944 void setPosChildNeedsLayoutBit(bool b) { m_bitfields.setPosChildNeedsLayout(b); } 945 void setNeedsSimplifiedNormalFlowLayoutBit(bool b) { m_bitfields.setNeedsSimplifiedNormalFlowLayout(b); } 943 946 944 947 private: … … 1078 1081 RenderObjectBitfields m_bitfields; 1079 1082 1080 void setNeedsPositionedMovementLayout(bool b) { m_bitfields.setNeedsPositionedMovementLayout(b); }1081 void setNormalChildNeedsLayout(bool b) { m_bitfields.setNormalChildNeedsLayout(b); }1082 void setPosChildNeedsLayout(bool b) { m_bitfields.setPosChildNeedsLayout(b); }1083 void setNeedsSimplifiedNormalFlowLayout(bool b) { m_bitfields.setNeedsSimplifiedNormalFlowLayout(b); }1084 1083 void setIsDragging(bool b) { m_bitfields.setIsDragging(b); } 1085 1084 void setEverHadLayout(bool b) { m_bitfields.setEverHadLayout(b); } … … 1116 1115 } 1117 1116 1118 inline void RenderObject::setChildNeedsLayout(bool childNeedsLayout, MarkingBehavior markParents) 1119 { 1120 bool alreadyNeededLayout = normalChildNeedsLayout(); 1121 setNormalChildNeedsLayout(childNeedsLayout); 1122 if (childNeedsLayout) { 1123 ASSERT(!isSetNeedsLayoutForbidden()); 1124 if (!alreadyNeededLayout && markParents == MarkContainingBlockChain) 1125 markContainingBlocksForLayout(); 1126 } else { 1127 setPosChildNeedsLayout(false); 1128 setNeedsSimplifiedNormalFlowLayout(false); 1129 setNormalChildNeedsLayout(false); 1130 setNeedsPositionedMovementLayout(false); 1131 } 1132 } 1133 1134 inline void RenderObject::setNeedsPositionedMovementLayout(const RenderStyle* oldStyle) 1135 { 1136 bool alreadyNeededLayout = needsPositionedMovementLayout(); 1137 setNeedsPositionedMovementLayout(true); 1117 inline void RenderObject::setNeedsLayout(MarkingBehavior markParents) 1118 { 1138 1119 ASSERT(!isSetNeedsLayoutForbidden()); 1139 if (!alreadyNeededLayout) { 1120 if (m_bitfields.needsLayout()) 1121 return; 1122 m_bitfields.setNeedsLayout(true); 1123 if (markParents == MarkContainingBlockChain) 1140 1124 markContainingBlocksForLayout(); 1141 if (hasLayer()) { 1142 if (oldStyle && style()->diffRequiresRepaint(oldStyle)) 1143 setLayerNeedsFullRepaint(); 1144 else 1145 setLayerNeedsFullRepaintForPositionedMovementLayout(); 1146 } 1147 } 1148 } 1149 1150 inline void RenderObject::setNeedsSimplifiedNormalFlowLayout() 1151 { 1152 bool alreadyNeededLayout = needsSimplifiedNormalFlowLayout(); 1153 setNeedsSimplifiedNormalFlowLayout(true); 1154 ASSERT(!isSetNeedsLayoutForbidden()); 1155 if (!alreadyNeededLayout) { 1156 markContainingBlocksForLayout(); 1157 if (hasLayer()) 1158 setLayerNeedsFullRepaint(); 1159 } 1125 if (hasLayer()) 1126 setLayerNeedsFullRepaint(); 1160 1127 } 1161 1128
Note:
See TracChangeset
for help on using the changeset viewer.