Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1626)

Unified Diff: Source/core/rendering/RenderLayer.h

Issue 14741004: NOT FOR REVIEW - Update comp-scrolling state at a well defined point in the pipeline. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: . Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/rendering/RenderLayer.h
diff --git a/Source/core/rendering/RenderLayer.h b/Source/core/rendering/RenderLayer.h
index 18e40590e594cca3686cdc7101d31c4686587d3d..a9ada13d713f0ded18fd442380798d51b02942d6 100644
--- a/Source/core/rendering/RenderLayer.h
+++ b/Source/core/rendering/RenderLayer.h
@@ -549,6 +549,7 @@ public:
// rendering of the page.
// FIXME: We should ASSERT(!m_hasOutOfFlowPositionedDescendantDirty); here but we may hit the same bugs as visible content above.
bool hasOutOfFlowPositionedDescendant() const { return m_hasOutOfFlowPositionedDescendant; }
+ void updateHasOutOfFlowPositionedDescendant(HashSet<const RenderObject*>* containingBlocks = 0);
// Gets the nearest enclosing positioned ancestor layer (also includes
// the <html> layer and the root layer).
@@ -814,6 +815,13 @@ public:
enum PaintOrderListType {BeforePromote, AfterPromote};
void computePaintOrderList(PaintOrderListType type, Vector<RefPtr<Node> >&);
+ enum ForceNeedsCompositedScrollingMode {
+ DoNotForceCompositedScrolling = 0,
+ ForceCompositedScrollingOn,
+ ForceCompositedScrollingOff
+ };
+ void setForceNeedsCompositedScrolling(ForceNeedsCompositedScrollingMode mode);
+
private:
enum CollectLayersBehavior { StopAtStackingContexts, StopAtStackingContainers };
@@ -833,8 +841,8 @@ private:
void dirtyAncestorChainHasSelfPaintingLayerDescendantStatus();
bool acceleratedCompositingForOverflowScrollEnabled() const;
- void updateDescendantsAreContiguousInStackingOrder();
- void updateDescendantsAreContiguousInStackingOrderRecursive(const HashMap<const RenderLayer*, int>&, int& minIndex, int& maxIndex, int& count, bool firstIteration);
+ void updateCanBeStackingContainer(RenderLayer*);
+ void updateCanBeStackingContainerRecursively(RenderLayer*);
void collectBeforePromotionZOrderList(RenderLayer* ancestorStackingContext, OwnPtr<Vector<RenderLayer*> >& posZOrderListBeforePromote, OwnPtr<Vector<RenderLayer*> >& negZOrderListBeforePromote);
void collectAfterPromotionZOrderList(RenderLayer* ancestorStackingContext, OwnPtr<Vector<RenderLayer*> >& posZOrderListAfterPromote, OwnPtr<Vector<RenderLayer*> >& negZOrderListAfterPromote);
@@ -856,11 +864,10 @@ private:
void updateScrollbarsAfterStyleChange(const RenderStyle* oldStyle);
void updateScrollbarsAfterLayout();
- void setAncestorChainHasOutOfFlowPositionedDescendant(RenderObject* containingBlock);
- void dirtyAncestorChainHasOutOfFlowPositionedDescendantStatus();
void updateOutOfFlowPositioned(const RenderStyle* oldStyle);
void updateNeedsCompositedScrolling();
+ void didUpdateNeedsCompositedScrolling();
// Returns true if the position changed.
bool updateLayerPosition();
@@ -1025,7 +1032,7 @@ private:
void dirtyAncestorChainVisibleDescendantStatus();
void setAncestorChainHasVisibleDescendant();
- void updateDescendantDependentFlags(HashSet<const RenderObject*>* outOfFlowDescendantContainingBlocks = 0);
+ void updateDescendantDependentFlags();
// This flag is computed by RenderLayerCompositor, which knows more about 3d hierarchies than we do.
void setHas3DTransformedDescendant(bool b) { m_has3DTransformedDescendant = b; }
@@ -1128,15 +1135,15 @@ protected:
// appears between our descendants in stacking order, then we may become a
// stacking context.
bool m_hasOutOfFlowPositionedDescendant : 1;
- bool m_hasOutOfFlowPositionedDescendantDirty : 1;
+ ForceNeedsCompositedScrollingMode m_forceNeedsCompositedScrolling;
bool m_needsCompositedScrolling : 1;
// If this is true, then no non-descendant appears between any of our
// descendants in stacking order. This is one of the requirements of being
// able to safely become a stacking context.
- bool m_descendantsAreContiguousInStackingOrder : 1;
- bool m_descendantsAreContiguousInStackingOrderDirty : 1;
+ bool m_canBePromotedToStackingContainer : 1;
+ bool m_canBePromotedToStackingContainerDirty : 1;
const bool m_isRootLayer : 1;

Powered by Google App Engine
This is Rietveld 408576698