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

Unified Diff: src/core/SkMaskCache.cpp

Issue 1955913002: Fix for Ubuntu compile warning (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Trying another way Created 4 years, 7 months 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkMaskCache.cpp
diff --git a/src/core/SkMaskCache.cpp b/src/core/SkMaskCache.cpp
index da7b538d3e40620c89a82508bfd3eb3f3da371f0..eb7c8f0941f359ff226b6cf37accaf4e9b0507e0 100644
--- a/src/core/SkMaskCache.cpp
+++ b/src/core/SkMaskCache.cpp
@@ -110,16 +110,15 @@ public:
SkASSERT(1 == count || 2 == count);
SkIRect ir;
rects[0].roundOut(&ir);
- fSizes[0] = SkSize::Make(0, 0);
- fSizes[1] = SkSize::Make(0, 0);
- fSizes[2] = SkSize::Make(0, 0);
- fSizes[3] = SkSize::Make(rects[0].x() - ir.x(), rects[0].y() - ir.y());
- for (int i = 0; i < count; i++) {
- fSizes[i] = SkSize::Make(rects[i].width(), rects[i].height());
- }
+ fSizes[0] = SkSize::Make(rects[0].width(), rects[0].height());
if (2 == count) {
+ fSizes[1] = SkSize::Make(rects[1].width(), rects[1].height());
fSizes[2] = SkSize::Make(rects[0].x() - rects[1].x(), rects[0].y() - rects[1].y());
+ } else {
+ fSizes[1] = SkSize::Make(0, 0);
+ fSizes[2] = SkSize::Make(0, 0);
}
+ fSizes[3] = SkSize::Make(rects[0].x() - ir.x(), rects[0].y() - ir.y());
this->init(&gRectsBlurKeyNamespaceLabel, 0,
sizeof(fSigma) + sizeof(fStyle) + sizeof(fQuality) + sizeof(fSizes));
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698