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

Unified Diff: third_party/WebKit/Source/platform/graphics/Path.cpp

Issue 2826773002: Rename CanvasPathMethods to CanvasPath (Closed)
Patch Set: x Created 3 years, 8 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 | « third_party/WebKit/Source/platform/graphics/Path.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/platform/graphics/Path.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/Path.cpp b/third_party/WebKit/Source/platform/graphics/Path.cpp
index a47b4cfde71c4728e716029af0c7e224db52250b..372a1d50e56ca54e56597064db14e676662e27b9 100644
--- a/third_party/WebKit/Source/platform/graphics/Path.cpp
+++ b/third_party/WebKit/Source/platform/graphics/Path.cpp
@@ -364,9 +364,7 @@ void Path::AddEllipse(const FloatPoint& p,
float start_angle,
float end_angle,
bool anticlockwise) {
-#if DCHECK_IS_ON()
DCHECK(EllipseIsRenderable(start_angle, end_angle));
-#endif
DCHECK_GE(start_angle, 0);
DCHECK_LT(start_angle, twoPiFloat);
DCHECK((anticlockwise && (start_angle - end_angle) >= 0) ||
@@ -428,9 +426,7 @@ void Path::AddEllipse(const FloatPoint& p,
float start_angle,
float end_angle,
bool anticlockwise) {
-#if DCHECK_IS_ON()
DCHECK(EllipseIsRenderable(start_angle, end_angle));
-#endif
DCHECK_GE(start_angle, 0);
DCHECK_LT(start_angle, twoPiFloat);
DCHECK((anticlockwise && (start_angle - end_angle) >= 0) ||
@@ -551,11 +547,9 @@ bool Path::IntersectPath(const Path& other) {
return Op(path_, other.path_, kIntersect_SkPathOp, &path_);
}
-#if DCHECK_IS_ON()
bool EllipseIsRenderable(float start_angle, float end_angle) {
return (std::abs(end_angle - start_angle) < twoPiFloat) ||
WebCoreFloatNearlyEqual(std::abs(end_angle - start_angle), twoPiFloat);
}
-#endif
} // namespace blink
« no previous file with comments | « third_party/WebKit/Source/platform/graphics/Path.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698