Chromium Code Reviews| Index: Source/core/rendering/exclusions/ExclusionPolygon.cpp |
| diff --git a/Source/core/rendering/exclusions/ExclusionPolygon.cpp b/Source/core/rendering/exclusions/ExclusionPolygon.cpp |
| index 1157041a79855fb6531f1759b801243710e59baf..5e2bbc1fe2752aa17fe1c171a1c46d4af635f923 100644 |
| --- a/Source/core/rendering/exclusions/ExclusionPolygon.cpp |
| +++ b/Source/core/rendering/exclusions/ExclusionPolygon.cpp |
| @@ -31,8 +31,7 @@ |
| #include "core/rendering/exclusions/ExclusionPolygon.h" |
| #include "core/platform/graphics/LayoutPoint.h" |
| - |
| -#include <wtf/MathExtras.h> |
| +#include "wtf/MathExtras.h" |
| namespace WebCore { |
| @@ -120,12 +119,12 @@ static inline void appendArc(Vector<FloatPoint>& vertices, const FloatPoint& arc |
| if (endAngle < 0) |
| endAngle += twoPI; |
| float angle = (startAngle > endAngle) ? (startAngle - endAngle) : (startAngle + twoPI - endAngle); |
| - const float arcSegmentCount = 5; // An odd number so that one arc vertex will be eactly arcRadius from arcCenter. |
| - float angle5 = ((padding) ? -angle : twoPI - angle) / arcSegmentCount; |
| + const float arcSegmentCount = 6; // An even number so that one arc vertex will be eactly arcRadius from arcCenter. |
|
leviw_travelin_and_unemployed
2013/05/21 19:32:05
I don't fully understand this change... Where did
|
| + float arcSegmentAngle = ((padding) ? -angle : twoPI - angle) / arcSegmentCount; |
| vertices.append(startArcVertex); |
| for (unsigned i = 1; i < arcSegmentCount; ++i) { |
| - float angle = startAngle + angle5 * i; |
| + float angle = startAngle + arcSegmentAngle * i; |
| vertices.append(arcCenter + FloatPoint(cos(angle) * arcRadius, sin(angle) * arcRadius)); |
| } |
| vertices.append(endArcVertex); |
| @@ -507,7 +506,7 @@ bool ExclusionPolygon::firstIncludedIntervalLogicalTop(LayoutUnit minLogicalInte |
| } |
| if (firstFitFound) |
| - result = LayoutUnit::fromFloatCeil(firstFitRect.y()); |
| + result = ceiledLayoutUnit(firstFitRect.y()); |
|
leviw_travelin_and_unemployed
2013/05/21 19:32:05
Are these different on WebKit then? They're the sa
leviw_travelin_and_unemployed
2013/05/21 22:21:56
Avoid this change
|
| return firstFitFound; |
| } |