Bug 1111222 - Use HasNonScalingStroke() more. r=dholbert

This commit is contained in:
Robert Longson 2014-12-17 13:58:31 +00:00
parent b8d80b14af
commit ab70fe95ea
3 changed files with 3 additions and 7 deletions

View File

@ -3536,8 +3536,7 @@ SVGTextFrame::NotifySVGChanged(uint32_t aFlags)
needNewBounds = true;
needGlyphMetricsUpdate = true;
}
if (StyleSVGReset()->mVectorEffect ==
NS_STYLE_VECTOR_EFFECT_NON_SCALING_STROKE) {
if (StyleSVGReset()->HasNonScalingStroke()) {
// Stroke currently contributes to our mRect, and our stroke depends on
// the transform to our outer-<svg> if |vector-effect:non-scaling-stroke|.
needNewBounds = true;

View File

@ -440,9 +440,7 @@ nsSVGPathGeometryFrame::NotifySVGChanged(uint32_t aFlags)
}
}
if ((aFlags & TRANSFORM_CHANGED) &&
StyleSVGReset()->mVectorEffect ==
NS_STYLE_VECTOR_EFFECT_NON_SCALING_STROKE) {
if ((aFlags & TRANSFORM_CHANGED) && StyleSVGReset()->HasNonScalingStroke()) {
// Stroke currently contributes to our mRect, and our stroke depends on
// the transform to our outer-<svg> if |vector-effect:non-scaling-stroke|.
nsSVGUtils::ScheduleReflowSVG(this);

View File

@ -1109,8 +1109,7 @@ nsSVGUtils::GetNonScalingStrokeTransform(nsIFrame *aFrame,
aFrame = aFrame->GetParent();
}
if (aFrame->StyleSVGReset()->mVectorEffect !=
NS_STYLE_VECTOR_EFFECT_NON_SCALING_STROKE) {
if (!aFrame->StyleSVGReset()->HasNonScalingStroke()) {
return false;
}