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

Unified Diff: third_party/WebKit/Source/platform/graphics/CrossfadeGeneratedImage.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/platform/graphics/CrossfadeGeneratedImage.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/CrossfadeGeneratedImage.cpp b/third_party/WebKit/Source/platform/graphics/CrossfadeGeneratedImage.cpp
index 9d19b6c59c598c86a1864e03732d6bdf449aaff0..19a095c3d87cff9f7f790d8f2f33305535c231b6 100644
--- a/third_party/WebKit/Source/platform/graphics/CrossfadeGeneratedImage.cpp
+++ b/third_party/WebKit/Source/platform/graphics/CrossfadeGeneratedImage.cpp
@@ -87,18 +87,18 @@ void CrossfadeGeneratedImage::draw(SkCanvas* canvas, const SkPaint& paint, const
canvas->restore();
}
-void CrossfadeGeneratedImage::drawTile(GraphicsContext* context, const FloatRect& srcRect)
+void CrossfadeGeneratedImage::drawTile(GraphicsContext& context, const FloatRect& srcRect)
{
// Draw nothing if either of the images hasn't loaded yet.
if (m_fromImage == Image::nullImage() || m_toImage == Image::nullImage())
return;
- SkPaint paint = context->fillPaint();
+ SkPaint paint = context.fillPaint();
paint.setXfermodeMode(SkXfermode::kSrcOver_Mode);
- paint.setAntiAlias(context->shouldAntialias());
+ paint.setAntiAlias(context.shouldAntialias());
FloatRect destRect((FloatPoint()), FloatSize(m_crossfadeSize));
- paint.setFilterQuality(context->computeFilterQuality(this, destRect, srcRect));
- drawCrossfade(context->canvas(), paint, ClampImageToSourceRect);
+ paint.setFilterQuality(context.computeFilterQuality(this, destRect, srcRect));
+ drawCrossfade(context.canvas(), paint, ClampImageToSourceRect);
}
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698