Index: Source/platform/graphics/GraphicsContext.cpp |
diff --git a/Source/platform/graphics/GraphicsContext.cpp b/Source/platform/graphics/GraphicsContext.cpp |
index 5f8fc1109c2669579e506d99d1ce31415100ce46..69cae52ea38d0d12fcb63c94c1742b96582aed76 100644 |
--- a/Source/platform/graphics/GraphicsContext.cpp |
+++ b/Source/platform/graphics/GraphicsContext.cpp |
@@ -179,14 +179,19 @@ void GraphicsContext::restore() |
m_canvas->restoreToCount(savedState.m_restoreCount); |
} |
-void GraphicsContext::saveLayer(const SkRect* bounds, const SkPaint* paint, SkCanvas::SaveFlags saveFlags) |
+void GraphicsContext::saveLayer(const SkRect* bounds, const SkPaint* paint, |
+ SkCanvas::SaveFlags extraFlags) |
{ |
if (paintingDisabled()) |
return; |
realizeCanvasSave(SkCanvas::kMatrixClip_SaveFlag); |
- m_canvas->saveLayer(bounds, paint, saveFlags); |
+ // Always save the clip & matrix. |
+ SkCanvas::SaveFlags flags = static_cast<SkCanvas::SaveFlags>( |
+ SkCanvas::kMatrixClip_SaveFlag | extraFlags); |
Stephen White
2014/03/26 17:45:52
Just an idea, but we could probably set these in t
f(malita)
2014/03/26 19:31:28
Done.
|
+ m_canvas->saveLayer(bounds, paint, flags); |
+ |
if (bounds) |
m_canvas->clipRect(*bounds); |
if (m_trackOpaqueRegion) |