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

Unified Diff: third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMasker.cpp

Issue 1512803004: Use refs for GraphicsContext (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ScrollbarTheme
Patch Set: Created 5 years 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: third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMasker.cpp
diff --git a/third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMasker.cpp b/third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMasker.cpp
index a68fe248ae40c8ef0a6d387ccee5f72027c05209..a794493cc26b0c8d96a135519df17605b072accc 100644
--- a/third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMasker.cpp
+++ b/third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceMasker.cpp
@@ -53,7 +53,7 @@ void LayoutSVGResourceMasker::removeClientFromCache(LayoutObject* client, bool m
}
PassRefPtr<const SkPicture> LayoutSVGResourceMasker::createContentPicture(AffineTransform& contentTransformation, const FloatRect& targetBoundingBox,
- GraphicsContext* context)
+ GraphicsContext& context)
{
SVGUnitTypes::SVGUnitType contentUnits = toSVGMaskElement(element())->maskContentUnits()->currentValue()->enumValue();
if (contentUnits == SVGUnitTypes::SVG_UNIT_TYPE_OBJECTBOUNDINGBOX) {
@@ -71,7 +71,7 @@ PassRefPtr<const SkPicture> LayoutSVGResourceMasker::createContentPicture(Affine
// userSpaceOnUse units (http://crbug.com/294900).
FloatRect bounds = strokeBoundingBox();
- SkPictureBuilder pictureBuilder(bounds, nullptr, context);
+ SkPictureBuilder pictureBuilder(bounds, nullptr, &context);
ColorFilter maskContentFilter = style()->svgStyle().colorInterpolation() == CI_LINEARRGB
? ColorFilterSRGBToLinearRGB : ColorFilterNone;
@@ -85,7 +85,7 @@ PassRefPtr<const SkPicture> LayoutSVGResourceMasker::createContentPicture(Affine
if (!style || style->display() == NONE || style->visibility() != VISIBLE)
continue;
- SVGPaintContext::paintSubtree(&pictureBuilder.context(), layoutObject);
+ SVGPaintContext::paintSubtree(pictureBuilder.context(), layoutObject);
}
m_maskContentPicture = pictureBuilder.endRecording();

Powered by Google App Engine
This is Rietveld 408576698