| Index: Source/core/rendering/svg/RenderSVGRoot.cpp
|
| diff --git a/Source/core/rendering/svg/RenderSVGRoot.cpp b/Source/core/rendering/svg/RenderSVGRoot.cpp
|
| index 242406573d20bf86bf8f5ad03d5651a7b043488a..53f9b463e6b9f12c7434f41eafc79a5c0032e2ca 100644
|
| --- a/Source/core/rendering/svg/RenderSVGRoot.cpp
|
| +++ b/Source/core/rendering/svg/RenderSVGRoot.cpp
|
| @@ -42,6 +42,7 @@
|
| #include "core/svg/SVGElement.h"
|
| #include "core/svg/SVGSVGElement.h"
|
| #include "core/svg/graphics/SVGImage.h"
|
| +#include "platform/LengthFunctions.h"
|
|
|
| using namespace std;
|
|
|
| @@ -82,9 +83,9 @@ void RenderSVGRoot::computeIntrinsicRatioInformation(FloatSize& intrinsicSize, d
|
| // resolving both values to user units.
|
| if (intrinsicWidthAttribute.isFixed() || intrinsicHeightAttribute.isFixed()) {
|
| if (intrinsicWidthAttribute.isFixed())
|
| - intrinsicSize.setWidth(floatValueForLength(intrinsicWidthAttribute, 0, 0));
|
| + intrinsicSize.setWidth(floatValueForLength(intrinsicWidthAttribute, 0));
|
| if (intrinsicHeightAttribute.isFixed())
|
| - intrinsicSize.setHeight(floatValueForLength(intrinsicHeightAttribute, 0, 0));
|
| + intrinsicSize.setHeight(floatValueForLength(intrinsicHeightAttribute, 0));
|
| if (!intrinsicSize.isEmpty())
|
| intrinsicRatio = intrinsicSize.width() / static_cast<double>(intrinsicSize.height());
|
| return;
|
| @@ -131,9 +132,9 @@ bool RenderSVGRoot::isEmbeddedThroughFrameContainingSVGDocument() const
|
| return frame->document()->isSVGDocument();
|
| }
|
|
|
| -static inline LayoutUnit resolveLengthAttributeForSVG(const Length& length, float scale, float maxSize, RenderView* renderView)
|
| +static inline LayoutUnit resolveLengthAttributeForSVG(const Length& length, float scale, float maxSize)
|
| {
|
| - return static_cast<LayoutUnit>(valueForLength(length, maxSize, renderView) * (length.isFixed() ? scale : 1));
|
| + return static_cast<LayoutUnit>(valueForLength(length, maxSize) * (length.isFixed() ? scale : 1));
|
| }
|
|
|
| LayoutUnit RenderSVGRoot::computeReplacedLogicalWidth(ShouldComputePreferred shouldComputePreferred) const
|
| @@ -149,7 +150,7 @@ LayoutUnit RenderSVGRoot::computeReplacedLogicalWidth(ShouldComputePreferred sho
|
| return RenderReplaced::computeReplacedLogicalWidth(shouldComputePreferred);
|
|
|
| if (svg->widthAttributeEstablishesViewport())
|
| - return resolveLengthAttributeForSVG(svg->intrinsicWidth(SVGSVGElement::IgnoreCSSProperties), style()->effectiveZoom(), containingBlock()->availableLogicalWidth(), view());
|
| + return resolveLengthAttributeForSVG(svg->intrinsicWidth(SVGSVGElement::IgnoreCSSProperties), style()->effectiveZoom(), containingBlock()->availableLogicalWidth());
|
|
|
| // SVG embedded through object/embed/iframe.
|
| if (isEmbeddedThroughFrameContainingSVGDocument())
|
| @@ -183,7 +184,7 @@ LayoutUnit RenderSVGRoot::computeReplacedLogicalHeight() const
|
| } else
|
| RenderBlock::removePercentHeightDescendant(const_cast<RenderSVGRoot*>(this));
|
|
|
| - return resolveLengthAttributeForSVG(height, style()->effectiveZoom(), containingBlock()->availableLogicalHeight(IncludeMarginBorderPadding), view());
|
| + return resolveLengthAttributeForSVG(height, style()->effectiveZoom(), containingBlock()->availableLogicalHeight(IncludeMarginBorderPadding));
|
| }
|
|
|
| // SVG embedded through object/embed/iframe.
|
|
|