| Index: Source/WebCore/platform/graphics/chromium/LayerRendererChromium.cpp
|
| ===================================================================
|
| --- Source/WebCore/platform/graphics/chromium/LayerRendererChromium.cpp (revision 94434)
|
| +++ Source/WebCore/platform/graphics/chromium/LayerRendererChromium.cpp (working copy)
|
| @@ -198,7 +198,7 @@
|
| {
|
| if (m_rootCCLayerImpl)
|
| clearRenderSurfacesOnCCLayerImplRecursive(m_rootCCLayerImpl.get());
|
| - m_computedRenderSurfaceLayerList.clear();
|
| + m_computedRenderSurfaceLayerList = adoptPtr(new LayerList());
|
| m_rootCCLayerImpl.clear();
|
| }
|
|
|
| @@ -304,8 +304,13 @@
|
| m_rootCCLayerImpl = TreeSynchronizer::synchronizeTrees(m_rootLayer.get(), m_rootCCLayerImpl.get());
|
| }
|
|
|
| - m_computedRenderSurfaceLayerList = adoptPtr(new LayerList());
|
| - updateLayers(*m_computedRenderSurfaceLayerList);
|
| + OwnPtr<LayerList> temporaryLayerList = adoptPtr(new LayerList());
|
| + updateLayers(*temporaryLayerList);
|
| +
|
| + if (m_rootLayer)
|
| + m_computedRenderSurfaceLayerList = temporaryLayerList.release();
|
| + else
|
| + m_computedRenderSurfaceLayerList = adoptPtr(new LayerList());
|
| }
|
|
|
| void LayerRendererChromium::drawLayers()
|
| @@ -381,6 +386,10 @@
|
| m_rootLayerContentTiler->updateRect(m_rootLayerTextureUpdater.get());
|
| }
|
|
|
| + // Painting could turn off compositing, so check for the root layer.
|
| + if (!m_rootLayer)
|
| + return;
|
| +
|
| m_contentsTextureManager->reduceMemoryToLimit(textureMemoryReclaimLimitBytes);
|
| updateCompositorResources(renderSurfaceLayerList);
|
| }
|
|
|