Index: third_party/WebKit/Source/core/svg/SVGGraphicsElement.cpp |
diff --git a/third_party/WebKit/Source/core/svg/SVGGraphicsElement.cpp b/third_party/WebKit/Source/core/svg/SVGGraphicsElement.cpp |
index 10a820de5479b7abfede32a61fe36b9dfea5d44d..8bd4d3987f146f621421c9f945bac17be7eb23c6 100644 |
--- a/third_party/WebKit/Source/core/svg/SVGGraphicsElement.cpp |
+++ b/third_party/WebKit/Source/core/svg/SVGGraphicsElement.cpp |
@@ -114,7 +114,9 @@ bool SVGGraphicsElement::hasAnimatedLocalTransform() const { |
const ComputedStyle* style = |
layoutObject() ? layoutObject()->style() : nullptr; |
- // Each of these is used in SVGGraphicsElement::calculateAnimatedLocalTransform to create an animated local transform. |
+ // Each of these is used in |
+ // SVGGraphicsElement::calculateAnimatedLocalTransform to create an animated |
+ // local transform. |
return (style && style->hasTransform()) || |
!m_transform->currentValue()->isEmpty() || hasSVGRareData(); |
} |
@@ -124,27 +126,32 @@ AffineTransform SVGGraphicsElement::calculateAnimatedLocalTransform() const { |
const ComputedStyle* style = |
layoutObject() ? layoutObject()->style() : nullptr; |
- // If CSS property was set, use that, otherwise fallback to attribute (if set). |
+ // If CSS property was set, use that, otherwise fallback to attribute (if |
+ // set). |
if (style && style->hasTransform()) { |
TransformationMatrix transform; |
float zoom = style->effectiveZoom(); |
// SVGTextElements need special handling for the text positioning code. |
if (isSVGTextElement(this)) { |
- // Do not take into account SVG's zoom rules, transform-origin, or percentage values. |
+ // Do not take into account SVG's zoom rules, transform-origin, or |
+ // percentage values. |
style->applyTransform( |
transform, LayoutSize(0, 0), ComputedStyle::ExcludeTransformOrigin, |
ComputedStyle::IncludeMotionPath, |
ComputedStyle::IncludeIndependentTransformProperties); |
} else { |
- // CSS transforms operate with pre-scaled lengths. To make this work with SVG |
- // (which applies the zoom factor globally, at the root level) we |
+ // CSS transforms operate with pre-scaled lengths. To make this work with |
+ // SVG (which applies the zoom factor globally, at the root level) we |
// |
- // * pre-scale the bounding box (to bring it into the same space as the other CSS values) |
- // * invert the zoom factor (to effectively compute the CSS transform under a 1.0 zoom) |
+ // * pre-scale the bounding box (to bring it into the same space as the |
+ // other CSS values) |
+ // * invert the zoom factor (to effectively compute the CSS transform |
+ // under a 1.0 zoom) |
// |
- // Note: objectBoundingBox is an emptyRect for elements like pattern or clipPath. |
- // See the "Object bounding box units" section of http://dev.w3.org/csswg/css3-transforms/ |
+ // Note: objectBoundingBox is an emptyRect for elements like pattern or |
+ // clipPath. See the "Object bounding box units" section of |
+ // http://dev.w3.org/csswg/css3-transforms/ |
if (zoom != 1) { |
FloatRect scaledBBox = layoutObject()->objectBoundingBox(); |
scaledBBox.scale(zoom); |
@@ -179,7 +186,8 @@ AffineTransform* SVGGraphicsElement::animateMotionTransform() { |
} |
void SVGGraphicsElement::svgAttributeChanged(const QualifiedName& attrName) { |
- // Reattach so the isValid() check will be run again during layoutObject creation. |
+ // Reattach so the isValid() check will be run again during layoutObject |
+ // creation. |
if (SVGTests::isKnownAttribute(attrName)) { |
SVGElement::InvalidationGuard invalidationGuard(this); |
lazyReattachIfAttached(); |