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

Unified Diff: Source/core/rendering/svg/SVGTextLayoutEngineBaseline.cpp

Issue 112003003: [SVG] SVGLength{,List} migration to new SVG property impl. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: revert aggressive svgAttributeChanged, add NeedsRebaseline Created 6 years, 11 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: Source/core/rendering/svg/SVGTextLayoutEngineBaseline.cpp
diff --git a/Source/core/rendering/svg/SVGTextLayoutEngineBaseline.cpp b/Source/core/rendering/svg/SVGTextLayoutEngineBaseline.cpp
index 3825b4b1220fe9eebd40fa21a6a8c158b5cdac5e..502c397993df7a5cb4fcc6f2206b1dd57087f867 100644
--- a/Source/core/rendering/svg/SVGTextLayoutEngineBaseline.cpp
+++ b/Source/core/rendering/svg/SVGTextLayoutEngineBaseline.cpp
@@ -38,12 +38,12 @@ SVGTextLayoutEngineBaseline::SVGTextLayoutEngineBaseline(const Font& font)
float SVGTextLayoutEngineBaseline::calculateBaselineShift(const SVGRenderStyle* style, SVGElement* contextElement) const
{
if (style->baselineShift() == BS_LENGTH) {
- SVGLength baselineShiftValueLength = style->baselineShiftValue();
- if (baselineShiftValueLength.unitType() == LengthTypePercentage)
- return baselineShiftValueLength.valueAsPercentage() * m_font.pixelSize();
+ RefPtr<SVGLength> baselineShiftValueLength = style->baselineShiftValue();
+ if (baselineShiftValueLength->unitType() == LengthTypePercentage)
+ return baselineShiftValueLength->valueAsPercentage() * m_font.pixelSize();
SVGLengthContext lengthContext(contextElement);
- return baselineShiftValueLength.value(lengthContext);
+ return baselineShiftValueLength->value(lengthContext);
}
switch (style->baselineShift()) {
« no previous file with comments | « Source/core/rendering/svg/SVGTextLayoutEngine.cpp ('k') | Source/core/rendering/svg/SVGTextLayoutEngineSpacing.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698