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

Unified Diff: src/core/SkRRect.cpp

Issue 1003813003: some utils for rect and matrix (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 9 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 | « src/core/SkDraw.cpp ('k') | src/core/SkRasterizer.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkRRect.cpp
diff --git a/src/core/SkRRect.cpp b/src/core/SkRRect.cpp
index f2927644daabd40dbbe79f6964f2dfe305e56748..d8b4a20d88dfd5987209bc78114fec405886b000 100644
--- a/src/core/SkRRect.cpp
+++ b/src/core/SkRRect.cpp
@@ -453,9 +453,8 @@ bool SkRRect::transform(const SkMatrix& matrix, SkRRect* dst) const {
///////////////////////////////////////////////////////////////////////////////
void SkRRect::inset(SkScalar dx, SkScalar dy, SkRRect* dst) const {
- SkRect r = fRect;
+ const SkRect r = fRect.makeInset(dx, dy);
- r.inset(dx, dy);
if (r.isEmpty()) {
dst->setEmpty();
return;
« no previous file with comments | « src/core/SkDraw.cpp ('k') | src/core/SkRasterizer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698