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

Side by Side Diff: third_party/WebKit/Source/core/svg/SVGPathQuery.cpp

Issue 2748223002: Replace ASSERT_NOT_REACHED with NOTREACHED in core/svg/ (Closed)
Patch Set: Created 3 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Nikolas Zimmermann 2 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Nikolas Zimmermann
3 * <zimmermann@kde.org> 3 * <zimmermann@kde.org>
4 * Copyright (C) 2004, 2005 Rob Buis <buis@kde.org> 4 * Copyright (C) 2004, 2005 Rob Buis <buis@kde.org>
5 * Copyright (C) 2007 Eric Seidel <eric@webkit.org> 5 * Copyright (C) 2007 Eric Seidel <eric@webkit.org>
6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 m_traversalState.lineTo(segment.targetPoint); 72 m_traversalState.lineTo(segment.targetPoint);
73 break; 73 break;
74 case PathSegClosePath: 74 case PathSegClosePath:
75 m_traversalState.m_totalLength += m_traversalState.closeSubpath(); 75 m_traversalState.m_totalLength += m_traversalState.closeSubpath();
76 break; 76 break;
77 case PathSegCurveToCubicAbs: 77 case PathSegCurveToCubicAbs:
78 m_traversalState.m_totalLength += m_traversalState.cubicBezierTo( 78 m_traversalState.m_totalLength += m_traversalState.cubicBezierTo(
79 segment.point1, segment.point2, segment.targetPoint); 79 segment.point1, segment.point2, segment.targetPoint);
80 break; 80 break;
81 default: 81 default:
82 ASSERT_NOT_REACHED(); 82 NOTREACHED();
83 } 83 }
84 } 84 }
85 85
86 void executeQuery(const SVGPathByteStream& pathByteStream, 86 void executeQuery(const SVGPathByteStream& pathByteStream,
87 SVGPathTraversalState& traversalState) { 87 SVGPathTraversalState& traversalState) {
88 SVGPathByteStreamSource source(pathByteStream); 88 SVGPathByteStreamSource source(pathByteStream);
89 SVGPathNormalizer normalizer(&traversalState); 89 SVGPathNormalizer normalizer(&traversalState);
90 90
91 bool hasMoreData = source.hasMoreData(); 91 bool hasMoreData = source.hasMoreData();
92 while (hasMoreData) { 92 while (hasMoreData) {
(...skipping 28 matching lines...) Expand all
121 } 121 }
122 122
123 FloatPoint SVGPathQuery::getPointAtLength(float length) const { 123 FloatPoint SVGPathQuery::getPointAtLength(float length) const {
124 SVGPathTraversalState traversalState( 124 SVGPathTraversalState traversalState(
125 PathTraversalState::TraversalPointAtLength, length); 125 PathTraversalState::TraversalPointAtLength, length);
126 executeQuery(m_pathByteStream, traversalState); 126 executeQuery(m_pathByteStream, traversalState);
127 return traversalState.computedPoint(); 127 return traversalState.computedPoint();
128 } 128 }
129 129
130 } // namespace blink 130 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/svg/SVGPathParser.cpp ('k') | third_party/WebKit/Source/core/svg/SVGPathStringBuilder.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698