Chromium Code Reviews| Index: third_party/WebKit/Source/platform/graphics/GraphicsLayer.cpp |
| diff --git a/third_party/WebKit/Source/platform/graphics/GraphicsLayer.cpp b/third_party/WebKit/Source/platform/graphics/GraphicsLayer.cpp |
| index 2b2ec9c4267bc42879927ba9be05f8571a3811a9..5033035c9d7396472ae0a246e189917d70616eee 100644 |
| --- a/third_party/WebKit/Source/platform/graphics/GraphicsLayer.cpp |
| +++ b/third_party/WebKit/Source/platform/graphics/GraphicsLayer.cpp |
| @@ -299,7 +299,20 @@ void GraphicsLayer::paintIfNeeded(GraphicsContext& context) |
| if (firstPaintInvalidationTrackingEnabled()) |
| m_debugInfo.clearAnnotatedInvalidateRects(); |
| incrementPaintCount(); |
| +#ifndef NDEBUG |
| + if (m_paintController && contentsOpaque() && s_drawDebugRedFill) { |
| + FloatRect rect(FloatPoint(), size()); |
| + if (!DrawingRecorder::useCachedDrawingIfPossible(context, *this, DisplayItem::DebugRedFill)) { |
| + DrawingRecorder recorder(context, *this, DisplayItem::DebugRedFill, rect); |
| + context.fillRect(rect, SK_ColorRED); |
| + } |
| + } |
| +#endif |
|
Xianzhu
2015/10/28 18:10:23
These are copied from GraphicsLayer::paint().
Per
|
| m_client->paintContentsIfNeeded(this, context, m_paintingPhase); |
| + if (!m_textPainted && m_paintController->textPainted()) { |
| + m_textPainted = true; |
| + m_client->notifyTextPainted(); |
| + } |
| } |
| void GraphicsLayer::paint(GraphicsContext& context, const IntRect& clip) |