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

Unified Diff: third_party/WebKit/Source/core/svg/graphics/SVGImage.cpp

Issue 1447273003: Make the FloatSize constructor from an IntSize explicit. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month 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/svg/graphics/SVGImage.cpp
diff --git a/third_party/WebKit/Source/core/svg/graphics/SVGImage.cpp b/third_party/WebKit/Source/core/svg/graphics/SVGImage.cpp
index f82b56dc81efe442ce2add2a307ffd6110df9e8e..4e15438852088bdfa88c01423270ceaecc7e7ba9 100644
--- a/third_party/WebKit/Source/core/svg/graphics/SVGImage.cpp
+++ b/third_party/WebKit/Source/core/svg/graphics/SVGImage.cpp
@@ -223,7 +223,7 @@ PassRefPtr<SkImage> SVGImage::imageForCurrentFrame()
SkPictureRecorder recorder;
SkCanvas* canvas = recorder.beginRecording(width(), height());
- drawForContainer(canvas, SkPaint(), size(), 1, rect(), rect());
+ drawForContainer(canvas, SkPaint(), FloatSize(size()), 1, rect(), rect());
RefPtr<SkPicture> picture = adoptRef(recorder.endRecording());
return adoptRef(
@@ -241,7 +241,7 @@ void SVGImage::drawPatternForContainer(GraphicsContext* context, const FloatSize
// Expand the tile to account for repeat spacing.
FloatRect spacedTile(tile);
- spacedTile.expand(repeatSpacing);
+ spacedTile.expand(FloatSize(repeatSpacing));
SkPictureBuilder patternPicture(spacedTile, nullptr, context);
if (!DrawingRecorder::useCachedDrawingIfPossible(patternPicture.context(), *this, DisplayItem::Type::SVGImage)) {

Powered by Google App Engine
This is Rietveld 408576698