Chromium Code Reviews| Index: Source/core/layout/FloatingObjects.h |
| diff --git a/Source/core/layout/FloatingObjects.h b/Source/core/layout/FloatingObjects.h |
| index d8b23de4d17c1503e4c8ddcc599c0b2425532ccd..765a6da0c0d8b037a6d45a40d6de8b419fbd662b 100644 |
| --- a/Source/core/layout/FloatingObjects.h |
| +++ b/Source/core/layout/FloatingObjects.h |
| @@ -87,6 +87,8 @@ public: |
| void setShouldPaint(bool shouldPaint) { m_shouldPaint = shouldPaint; } |
| bool isDescendant() const { return m_isDescendant; } |
| void setIsDescendant(bool isDescendant) { m_isDescendant = isDescendant; } |
| + bool isLowestNonOverhangingFloatInChild() const { return m_isLowestNonOverhangingFloatInChild; } |
| + void setIsLowestNonOverhangingFloatInChild(bool isLowestNonOverhangingFloatInChild) { m_isLowestNonOverhangingFloatInChild = isLowestNonOverhangingFloatInChild; } |
| // FIXME: Callers of these methods are dangerous and should be whitelisted explicitly or removed. |
| RootInlineBox* originatingLine() const { return m_originatingLine; } |
| @@ -94,7 +96,7 @@ public: |
| private: |
| explicit FloatingObject(LayoutBox*); |
| - FloatingObject(LayoutBox*, Type, const LayoutRect&, bool shouldPaint, bool isDescendant); |
| + FloatingObject(LayoutBox*, Type, const LayoutRect&, bool shouldPaint, bool isDescendant, bool isLowestNonOverhangingFloatInChild); |
| LayoutBox* m_layoutObject; |
| RootInlineBox* m_originatingLine; |
| @@ -108,6 +110,7 @@ private: |
| #if ENABLE(ASSERT) |
| unsigned m_isInPlacedTree : 1; |
| #endif |
| + unsigned m_isLowestNonOverhangingFloatInChild : 1; |
|
leviw_travelin_and_unemployed
2015/05/22 20:52:01
Nit: I'd put this above the assertion-only member.
|
| }; |
| struct FloatingObjectHashFunctions { |
| @@ -158,11 +161,13 @@ public: |
| LayoutUnit logicalRightOffsetForPositioningFloat(LayoutUnit fixedOffset, LayoutUnit logicalTop, LayoutUnit* heightRemaining); |
| LayoutUnit lowestFloatLogicalBottom(FloatingObject::Type); |
| + FloatingObject* lowestFloatObject() { return m_lowestFloatObject; } |
| private: |
| bool hasLowestFloatLogicalBottomCached(bool isHorizontal, FloatingObject::Type floatType) const; |
| LayoutUnit getCachedlowestFloatLogicalBottom(FloatingObject::Type floatType) const; |
| void setCachedLowestFloatLogicalBottom(bool isHorizontal, FloatingObject::Type floatType, LayoutUnit value); |
| + void setLowestFloatObject(FloatingObject* object) { m_lowestFloatObject = object; } |
| void markLowestFloatLogicalBottomCacheAsDirty(); |
| void computePlacedFloatsTree(); |
| @@ -190,6 +195,7 @@ private: |
| }; |
| FloatBottomCachedValue m_lowestFloatBottomCache[2]; |
| bool m_cachedHorizontalWritingMode; |
| + FloatingObject* m_lowestFloatObject; |
|
leviw_travelin_and_unemployed
2015/05/22 20:52:01
m_lowestFloatingObject?
Would it maybe make sense
rhogan
2015/05/23 11:56:51
Yes, I think it might. I'll try it and see.
rhogan
2015/05/23 12:12:08
It doesn't fit well with m_lowestFloatBottomCache
|
| }; |
| #ifndef NDEBUG |