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

Unified Diff: third_party/WebKit/Source/core/svg/SVGTextContentElement.cpp

Issue 2912663002: Clean up creation of "detached" SVG* data type objects (Closed)
Patch Set: Created 3 years, 7 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
Index: third_party/WebKit/Source/core/svg/SVGTextContentElement.cpp
diff --git a/third_party/WebKit/Source/core/svg/SVGTextContentElement.cpp b/third_party/WebKit/Source/core/svg/SVGTextContentElement.cpp
index 7ff71ab8ecbc60afd92c87b87f538d4df47661bd..d5e318014195550bc46cafda4d3ffed2e310a411 100644
--- a/third_party/WebKit/Source/core/svg/SVGTextContentElement.cpp
+++ b/third_party/WebKit/Source/core/svg/SVGTextContentElement.cpp
@@ -138,8 +138,7 @@ SVGPointTearOff* SVGTextContentElement::getStartPositionOfChar(
FloatPoint point =
SVGTextQuery(GetLayoutObject()).StartPositionOfCharacter(charnum);
- return SVGPointTearOff::Create(SVGPoint::Create(point), 0,
- kPropertyIsNotAnimVal);
+ return SVGPointTearOff::CreateDetached(point);
}
SVGPointTearOff* SVGTextContentElement::getEndPositionOfChar(
@@ -156,8 +155,7 @@ SVGPointTearOff* SVGTextContentElement::getEndPositionOfChar(
FloatPoint point =
SVGTextQuery(GetLayoutObject()).EndPositionOfCharacter(charnum);
- return SVGPointTearOff::Create(SVGPoint::Create(point), 0,
- kPropertyIsNotAnimVal);
+ return SVGPointTearOff::CreateDetached(point);
}
SVGRectTearOff* SVGTextContentElement::getExtentOfChar(
@@ -173,8 +171,7 @@ SVGRectTearOff* SVGTextContentElement::getExtentOfChar(
}
FloatRect rect = SVGTextQuery(GetLayoutObject()).ExtentOfCharacter(charnum);
- return SVGRectTearOff::Create(SVGRect::Create(rect), 0,
- kPropertyIsNotAnimVal);
+ return SVGRectTearOff::CreateDetached(rect);
}
float SVGTextContentElement::getRotationOfChar(

Powered by Google App Engine
This is Rietveld 408576698