Changeset 86713 in webkit


Ignore:
Timestamp:
May 17, 2011 3:34:22 PM (13 years ago)
Author:
commit-queue@webkit.org
Message:

2011-05-17 Nat Duca <nduca@chromium.org>

Reviewed by James Robinson.

[chromium] Always set layerRenderer, even on non-drawn-layers
https://bugs.webkit.org/show_bug.cgi?id=60977

This is a defensive fixe for crbug.com/82799, in which
a RenderLayer could not prepare itself because its owning layerImpl
had no associated layerRenderer. The underlying issue is that we
sometimes put renderSurfaces onto the list that won't actually render.
For now, the priority is to reduce fragility so that invisible layers
dont lead to crashers. We do this by being more agressive about
binding CCLayerImpls to the LayerRenderer, doing it all the time rather
than only when we think it will get rendered.

  • platform/graphics/chromium/LayerRendererChromium.cpp: (WebCore::LayerRendererChromium::paintLayerContents):
Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r86708 r86713  
     12011-05-17  Nat Duca  <nduca@chromium.org>
     2
     3        Reviewed by James Robinson.
     4
     5        [chromium] Always set layerRenderer, even on non-drawn-layers
     6        https://bugs.webkit.org/show_bug.cgi?id=60977
     7
     8        This is a defensive fixe for crbug.com/82799, in which
     9        a RenderLayer could not prepare itself because its owning layerImpl
     10        had no associated layerRenderer. The underlying issue is that we
     11        sometimes put renderSurfaces onto the list that won't actually render.
     12        For now, the priority is to reduce fragility so that invisible layers
     13        dont lead to crashers. We do this by being more agressive about
     14        binding CCLayerImpls to the LayerRenderer, doing it all the time rather
     15        than only when we think it will get rendered.
     16
     17        * platform/graphics/chromium/LayerRendererChromium.cpp:
     18        (WebCore::LayerRendererChromium::paintLayerContents):
     19
    1202011-05-17  Anders Carlsson  <andersca@apple.com>
    221
  • trunk/Source/WebCore/platform/graphics/chromium/LayerRendererChromium.cpp

    r86652 r86713  
    356356        ASSERT(renderSurface);
    357357
     358        // Make sure any renderSurfaceLayer is associated with this layerRenderer.
     359        // This is a defensive assignment in case the owner of this layer hasn't
     360        // set the layerRenderer on this layer already.
     361        renderSurfaceLayer->setLayerRenderer(this);
     362
    358363        // Render surfaces whose drawable area has zero width or height
    359364        // will have no layers associated with them and should be skipped.
     
    372377
    373378            LayerChromium* layer = ccLayerImpl->owner();
    374             if (layer->bounds().isEmpty())
    375                 continue;
    376379
    377380            layer->setLayerRenderer(this);
     381
    378382            if (layer->maskLayer())
    379383                layer->maskLayer()->setLayerRenderer(this);
     
    383387                    layer->replicaLayer()->maskLayer()->setLayerRenderer(this);
    384388            }
     389
     390            if (layer->bounds().isEmpty())
     391              continue;
    385392
    386393            IntRect targetSurfaceRect = ccLayerImpl->targetRenderSurface() ? ccLayerImpl->targetRenderSurface()->contentRect() : m_defaultRenderSurface->contentRect();
Note: See TracChangeset for help on using the changeset viewer.