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

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

Issue 15973002: Remove NonCompositedContentHost -- Take 2 (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: include xp rebaseline Created 7 years, 7 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.cpp
diff --git a/Source/core/rendering/RenderLayer.cpp b/Source/core/rendering/RenderLayer.cpp
index 6fd7c24921906d5ed4687b8b90ae673073959d90..f08560e83f1c1cb3c4c5ef196ee106781a067838 100644
--- a/Source/core/rendering/RenderLayer.cpp
+++ b/Source/core/rendering/RenderLayer.cpp
@@ -1508,13 +1508,8 @@ void RenderLayer::setFilterBackendNeedsRepaintingInRect(const LayoutRect& rect)
LayoutRect parentLayerRect = renderer()->localToContainerQuad(repaintQuad, parentLayer->renderer()).enclosingBoundingBox();
if (parentLayer->isComposited()) {
- if (!parentLayer->backing()->paintsIntoWindow()) {
- parentLayer->setBackingNeedsRepaintInRect(parentLayerRect);
- return;
- }
- // If the painting goes to window, redirect the painting to the parent RenderView.
- parentLayer = renderer()->view()->layer();
- parentLayerRect = renderer()->localToContainerQuad(repaintQuad, parentLayer->renderer()).enclosingBoundingBox();
+ parentLayer->setBackingNeedsRepaintInRect(parentLayerRect);
+ return;
}
if (parentLayer->paintsWithFilters()) {
@@ -3583,8 +3578,7 @@ void RenderLayer::paintLayer(GraphicsContext* context, const LayerPaintingInfo&
// but we need to ensure that we don't cache clip rects computed with the wrong root in this case.
if (context->updatingControlTints() || (paintingInfo.paintBehavior & PaintBehaviorFlattenCompositingLayers))
paintFlags |= PaintLayerTemporaryClipRects;
- else if (!backing()->paintsIntoWindow()
- && !backing()->paintsIntoCompositedAncestor()
+ else if (!backing()->paintsIntoCompositedAncestor()
&& !shouldDoSoftwarePaint(this, paintFlags & PaintLayerPaintingReflection)) {
// If this RenderLayer should paint into its backing, that will be done via RenderLayerBacking::paintIntoLayer().
return;
@@ -5496,8 +5490,7 @@ GraphicsLayer* RenderLayer::layerForScrollCorner() const
bool RenderLayer::paintsWithTransform(PaintBehavior paintBehavior) const
{
- bool paintsToWindow = !isComposited() || backing()->paintsIntoWindow();
- return transform() && ((paintBehavior & PaintBehaviorFlattenCompositingLayers) || paintsToWindow);
+ return transform() && ((paintBehavior & PaintBehaviorFlattenCompositingLayers) || !isComposited());
}
bool RenderLayer::backgroundIsKnownToBeOpaqueInRect(const LayoutRect& localRect) const
@@ -5753,14 +5746,7 @@ void RenderLayer::repaintIncludingDescendants()
void RenderLayer::setBackingNeedsRepaint()
{
ASSERT(isComposited());
- if (backing()->paintsIntoWindow()) {
- // If we're trying to repaint the placeholder document layer, propagate the
- // repaint to the native view system.
- RenderView* view = renderer()->view();
- if (view)
- view->repaintViewRectangle(absoluteBoundingBox());
- } else
- backing()->setContentsNeedDisplay();
+ backing()->setContentsNeedDisplay();
}
void RenderLayer::setBackingNeedsRepaintInRect(const LayoutRect& r)
@@ -5768,7 +5754,7 @@ void RenderLayer::setBackingNeedsRepaintInRect(const LayoutRect& r)
// https://bugs.webkit.org/show_bug.cgi?id=61159 describes an unreproducible crash here,
// so assert but check that the layer is composited.
ASSERT(isComposited());
- if (!isComposited() || backing()->paintsIntoWindow()) {
+ if (!isComposited()) {
// If we're trying to repaint the placeholder document layer, propagate the
// repaint to the native view system.
LayoutRect absRect(r);

Powered by Google App Engine
This is Rietveld 408576698