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

Unified Diff: src/core/SkClipStack.cpp

Issue 833193002: Remove SkPath::asRect (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 11 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 | « include/core/SkPath.h ('k') | src/core/SkPath.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkClipStack.cpp
diff --git a/src/core/SkClipStack.cpp b/src/core/SkClipStack.cpp
index d5462876d1b77574d553f7fc4a8af275b3aa2492..515596a9693451f3a8bc05b932405ef20ac975b4 100644
--- a/src/core/SkClipStack.cpp
+++ b/src/core/SkClipStack.cpp
@@ -112,8 +112,9 @@ void SkClipStack::Element::invertShapeFillType() {
void SkClipStack::Element::initPath(int saveCount, const SkPath& path, SkRegion::Op op,
bool doAA) {
if (!path.isInverseFillType()) {
- if (SkPath::kNone_PathAsRect != path.asRect()) {
- this->initRect(saveCount, path.getBounds(), op, doAA);
+ SkRect r;
+ if (path.isRect(&r)) {
+ this->initRect(saveCount, r, op, doAA);
return;
}
SkRect ovalRect;
« no previous file with comments | « include/core/SkPath.h ('k') | src/core/SkPath.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698