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

Unified Diff: Source/core/rendering/shapes/Shape.cpp

Issue 212223006: [CSS Shapes] Simplify RasterShape implementation (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fix style errors Created 6 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 | « Source/core/rendering/shapes/RasterShape.cpp ('k') | Source/core/rendering/shapes/ShapeInterval.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/shapes/Shape.cpp
diff --git a/Source/core/rendering/shapes/Shape.cpp b/Source/core/rendering/shapes/Shape.cpp
index d013a93ae0a21f8767a6ade261824e7c26837a8b..60925382763bf6d47b74089eac45ee46e5973f2f 100644
--- a/Source/core/rendering/shapes/Shape.cpp
+++ b/Source/core/rendering/shapes/Shape.cpp
@@ -202,7 +202,7 @@ PassOwnPtr<Shape> Shape::createRasterShape(Image* image, float threshold, const
if (startX == -1 && alphaAboveThreshold) {
startX = x;
} else if (startX != -1 && (!alphaAboveThreshold || x == imageRect.width() - 1)) {
- intervals->appendInterval(y + imageRect.y(), startX + imageRect.x(), x + imageRect.x());
+ intervals->intervalAt(y + imageRect.y()).unite(IntShapeInterval(startX + imageRect.x(), x + imageRect.x()));
startX = -1;
}
}
« no previous file with comments | « Source/core/rendering/shapes/RasterShape.cpp ('k') | Source/core/rendering/shapes/ShapeInterval.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698