| Index: sky/engine/core/rendering/RenderLayer.h
|
| diff --git a/sky/engine/core/rendering/RenderLayer.h b/sky/engine/core/rendering/RenderLayer.h
|
| index 5e7c4fd374cdfb1bfbaf7238940385d6e98577b2..dce790c38805d5465286dde0a4970a78f8b775e1 100644
|
| --- a/sky/engine/core/rendering/RenderLayer.h
|
| +++ b/sky/engine/core/rendering/RenderLayer.h
|
| @@ -182,7 +182,7 @@ public:
|
| // front. The hitTest method looks for mouse events by walking
|
| // layers that intersect the point from front to back.
|
| // paint() assumes that the caller will clip to the bounds of damageRect if necessary.
|
| - void paint(GraphicsContext*, const LayoutRect& damageRect, PaintBehavior = PaintBehaviorNormal, RenderObject* paintingRoot = 0, PaintLayerFlags = 0);
|
| + void paint(GraphicsContext*, const LayoutRect& damageRect, PaintBehavior = PaintBehaviorNormal, RenderObject* paintingRoot = 0);
|
| bool hitTest(const HitTestRequest&, HitTestResult&);
|
| bool hitTest(const HitTestRequest&, const HitTestLocation&, HitTestResult&);
|
| void paintOverlayScrollbars(GraphicsContext*, const LayoutRect& damageRect, PaintBehavior, RenderObject* paintingRoot = 0);
|
| @@ -304,9 +304,6 @@ public:
|
| return isRootLayer() || layerRenderer->isPositioned() || hasTransform();
|
| }
|
|
|
| - // paintLayer() assumes that the caller will clip to the bounds of the painting dirty if necessary.
|
| - void paintLayer(GraphicsContext*, const LayerPaintingInfo&, PaintLayerFlags);
|
| -
|
| bool scrollsOverflow() const;
|
|
|
| CompositingReasons potentialCompositingReasonsFromStyle() const { return m_potentialCompositingReasonsFromStyle; }
|
| @@ -423,6 +420,12 @@ public:
|
| void setShouldDoFullPaintInvalidationIncludingNonCompositingDescendants();
|
|
|
| private:
|
| + // TODO(ojan): Get rid of this. These are basically layer-tree-only paint phases.
|
| + enum PaintLayerFlags {
|
| + PaintContent,
|
| + PaintOverlayScrollbars,
|
| + };
|
| +
|
| // Bounding box in the coordinates of this layer.
|
| LayoutRect logicalBoundingBox() const;
|
|
|
| @@ -431,7 +434,7 @@ private:
|
| void setAncestorChainHasSelfPaintingLayerDescendant();
|
| void dirtyAncestorChainHasSelfPaintingLayerDescendantStatus();
|
|
|
| - void clipToRect(const LayerPaintingInfo&, GraphicsContext*, const ClipRect&, PaintLayerFlags, BorderRadiusClippingRule = IncludeSelfForBorderRadius);
|
| + void clipToRect(const LayerPaintingInfo&, GraphicsContext*, const ClipRect&, BorderRadiusClippingRule = IncludeSelfForBorderRadius);
|
| void restoreClip(GraphicsContext*, const LayoutRect& paintDirtyRect, const ClipRect&);
|
|
|
| void setNextSibling(RenderLayer* next) { m_next = next; }
|
| @@ -451,6 +454,9 @@ private:
|
|
|
| LayoutPoint renderBoxLocation() const { return renderer()->isBox() ? toRenderBox(renderer())->location() : LayoutPoint(); }
|
|
|
| + // paintLayer() assumes that the caller will clip to the bounds of the painting dirty if necessary.
|
| + void paintLayer(GraphicsContext*, const LayerPaintingInfo&, PaintLayerFlags);
|
| +
|
| // paintLayerContents() assumes that the caller will clip to the bounds of the painting dirty rect if necessary.
|
| void paintLayerContents(GraphicsContext*, const LayerPaintingInfo&, PaintLayerFlags);
|
|
|
| @@ -461,16 +467,15 @@ private:
|
| void collectFragments(LayerFragments&, const RenderLayer* rootLayer, const LayoutRect& dirtyRect,
|
| ClipRectsCacheSlot, const LayoutPoint* offsetFromRoot = 0,
|
| const LayoutSize& subPixelAccumulation = LayoutSize(), const LayoutRect* layerBoundingBox = 0);
|
| - void updatePaintingInfoForFragments(LayerFragments&, const LayerPaintingInfo&, PaintLayerFlags, bool shouldPaintContent, const LayoutPoint* offsetFromRoot);
|
| + void updatePaintingInfoForFragments(LayerFragments&, const LayerPaintingInfo&, bool shouldPaintContent, const LayoutPoint* offsetFromRoot);
|
| void paintBackgroundForFragments(const LayerFragments&, GraphicsContext*, GraphicsContext* transparencyLayerContext,
|
| - const LayoutRect& transparencyPaintDirtyRect, bool haveTransparency, const LayerPaintingInfo&, PaintBehavior, RenderObject* paintingRootForRenderer, PaintLayerFlags);
|
| + const LayoutRect& transparencyPaintDirtyRect, bool haveTransparency, const LayerPaintingInfo&, PaintBehavior, RenderObject* paintingRootForRenderer);
|
| void paintForegroundForFragments(const LayerFragments&, GraphicsContext*, GraphicsContext* transparencyLayerContext,
|
| - const LayoutRect& transparencyPaintDirtyRect, bool haveTransparency, const LayerPaintingInfo&, PaintBehavior, RenderObject* paintingRootForRenderer,
|
| - PaintLayerFlags);
|
| - void paintForegroundForFragmentsWithPhase(PaintPhase, const LayerFragments&, GraphicsContext*, const LayerPaintingInfo&, PaintBehavior, RenderObject* paintingRootForRenderer, PaintLayerFlags);
|
| - void paintOutlineForFragments(const LayerFragments&, GraphicsContext*, const LayerPaintingInfo&, PaintBehavior, RenderObject* paintingRootForRenderer, PaintLayerFlags);
|
| - void paintOverflowControlsForFragments(const LayerFragments&, GraphicsContext*, const LayerPaintingInfo&, PaintLayerFlags);
|
| - void paintMaskForFragments(const LayerFragments&, GraphicsContext*, const LayerPaintingInfo&, RenderObject* paintingRootForRenderer, PaintLayerFlags);
|
| + const LayoutRect& transparencyPaintDirtyRect, bool haveTransparency, const LayerPaintingInfo&, PaintBehavior, RenderObject* paintingRootForRenderer);
|
| + void paintForegroundForFragmentsWithPhase(PaintPhase, const LayerFragments&, GraphicsContext*, const LayerPaintingInfo&, PaintBehavior, RenderObject* paintingRootForRenderer);
|
| + void paintOutlineForFragments(const LayerFragments&, GraphicsContext*, const LayerPaintingInfo&, PaintBehavior, RenderObject* paintingRootForRenderer);
|
| + void paintOverflowControlsForFragments(const LayerFragments&, GraphicsContext*, const LayerPaintingInfo&);
|
| + void paintMaskForFragments(const LayerFragments&, GraphicsContext*, const LayerPaintingInfo&, RenderObject* paintingRootForRenderer);
|
| void paintChildClippingMaskForFragments(const LayerFragments&, GraphicsContext*, const LayerPaintingInfo&, RenderObject* paintingRootForRenderer, PaintLayerFlags);
|
|
|
| RenderLayer* hitTestLayer(RenderLayer* rootLayer, RenderLayer* containerLayer, const HitTestRequest& request, HitTestResult& result,
|
|
|