Title: [173866] trunk/Source/WebCore
Revision
173866
Author
cdu...@apple.com
Date
2014-09-22 23:00:35 -0700 (Mon, 22 Sep 2014)

Log Message

Unreviewed build fix after r173859.

Partial revert to fix debug build after r173859.

* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::remoteSVGRootElement):
* html/HTMLFrameOwnerElement.cpp:
(WebCore::HTMLFrameOwnerElement::getSVGDocument):
* page/EventHandler.cpp:
(WebCore::EventHandler::handleMousePressEvent):
(WebCore::EventHandler::handleMouseMoveEvent):
(WebCore::EventHandler::handleMouseReleaseEvent):
* page/Frame.cpp:
(WebCore::Frame::setPageAndTextZoomFactors):
* page/FrameView.cpp:
(WebCore::FrameView::scrollToAnchor):
* rendering/svg/RenderSVGBlock.h:
(WebCore::RenderSVGBlock::graphicsElement):
* rendering/svg/RenderSVGGradientStop.cpp:
(WebCore::RenderSVGGradientStop::gradientElement):
* rendering/svg/RenderSVGInline.h:
(WebCore::RenderSVGInline::graphicsElement):
* rendering/svg/RenderSVGResourceClipper.cpp:
(WebCore::RenderSVGResourceClipper::pathOnlyClipping):
* rendering/svg/RenderSVGResourceContainer.cpp:
(WebCore::RenderSVGResourceContainer::transformOnNonScalingStroke):
* rendering/svg/RenderSVGShape.h:
(WebCore::RenderSVGShape::graphicsElement):
* rendering/svg/RenderSVGTransformableContainer.h:
* rendering/svg/SVGRenderSupport.cpp:
(WebCore::SVGRenderSupport::updateMaskedAncestorShouldIsolateBlending):
* rendering/svg/SVGRenderTreeAsText.cpp:
(WebCore::operator<<):
* rendering/svg/SVGRenderingContext.cpp:
(WebCore::SVGRenderingContext::prepareToRenderSVGContent):
* rendering/svg/SVGResources.cpp:
(WebCore::targetReferenceFromResource):
* svg/SVGAElement.cpp:
(WebCore::SVGAElement::defaultEventHandler):
* svg/SVGAnimateElement.cpp:
(WebCore::SVGAnimateElement::calculateAnimatedValue):
* svg/SVGAnimationElement.cpp:
(WebCore::SVGAnimationElement::currentValuesForValuesAnimation):
* svg/SVGElement.cpp:
(WebCore::SVGElement::getBoundingBox):
* svg/SVGLinearGradientElement.cpp:
(WebCore::SVGLinearGradientElement::collectGradientAttributes):
* svg/SVGLocatable.cpp:
(WebCore::SVGLocatable::getTransformToElement):
* svg/SVGPolyElement.cpp:
(WebCore::SVGPolyElement::synchronizePoints):
(WebCore::SVGPolyElement::lookupOrCreatePointsWrapper):
* svg/SVGRadialGradientElement.cpp:
(WebCore::SVGRadialGradientElement::collectGradientAttributes):
* svg/SVGTextContentElement.cpp:
(WebCore::SVGTextContentElement::synchronizeTextLength):
(WebCore::SVGTextContentElement::lookupOrCreateTextLengthWrapper):
(WebCore::SVGTextContentElement::elementFromRenderer):
* svg/SVGUseElement.cpp:
(WebCore::SVGUseElement::toClipPath):
* svg/animation/SVGSMILElement.cpp:
(WebCore::SVGSMILElement::connectConditions):
(WebCore::SVGSMILElement::disconnectConditions):
* svg/graphics/SVGImage.cpp:
(WebCore::SVGImage::hasSingleSecurityOrigin):
(WebCore::SVGImage::setContainerSize):
(WebCore::SVGImage::containerSize):
(WebCore::SVGImage::embeddedContentBox):
(WebCore::SVGImage::hasRelativeWidth):
(WebCore::SVGImage::hasRelativeHeight):
(WebCore::SVGImage::computeIntrinsicDimensions):
(WebCore::SVGImage::startAnimation):
(WebCore::SVGImage::stopAnimation):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (173865 => 173866)


--- trunk/Source/WebCore/ChangeLog	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/ChangeLog	2014-09-23 06:00:35 UTC (rev 173866)
@@ -1,3 +1,79 @@
+2014-09-22  Christophe Dumez  <cdu...@apple.com>
+
+        Unreviewed build fix after r173859.
+
+        Partial revert to fix debug build after r173859.
+
+        * accessibility/AccessibilityRenderObject.cpp:
+        (WebCore::AccessibilityRenderObject::remoteSVGRootElement):
+        * html/HTMLFrameOwnerElement.cpp:
+        (WebCore::HTMLFrameOwnerElement::getSVGDocument):
+        * page/EventHandler.cpp:
+        (WebCore::EventHandler::handleMousePressEvent):
+        (WebCore::EventHandler::handleMouseMoveEvent):
+        (WebCore::EventHandler::handleMouseReleaseEvent):
+        * page/Frame.cpp:
+        (WebCore::Frame::setPageAndTextZoomFactors):
+        * page/FrameView.cpp:
+        (WebCore::FrameView::scrollToAnchor):
+        * rendering/svg/RenderSVGBlock.h:
+        (WebCore::RenderSVGBlock::graphicsElement):
+        * rendering/svg/RenderSVGGradientStop.cpp:
+        (WebCore::RenderSVGGradientStop::gradientElement):
+        * rendering/svg/RenderSVGInline.h:
+        (WebCore::RenderSVGInline::graphicsElement):
+        * rendering/svg/RenderSVGResourceClipper.cpp:
+        (WebCore::RenderSVGResourceClipper::pathOnlyClipping):
+        * rendering/svg/RenderSVGResourceContainer.cpp:
+        (WebCore::RenderSVGResourceContainer::transformOnNonScalingStroke):
+        * rendering/svg/RenderSVGShape.h:
+        (WebCore::RenderSVGShape::graphicsElement):
+        * rendering/svg/RenderSVGTransformableContainer.h:
+        * rendering/svg/SVGRenderSupport.cpp:
+        (WebCore::SVGRenderSupport::updateMaskedAncestorShouldIsolateBlending):
+        * rendering/svg/SVGRenderTreeAsText.cpp:
+        (WebCore::operator<<):
+        * rendering/svg/SVGRenderingContext.cpp:
+        (WebCore::SVGRenderingContext::prepareToRenderSVGContent):
+        * rendering/svg/SVGResources.cpp:
+        (WebCore::targetReferenceFromResource):
+        * svg/SVGAElement.cpp:
+        (WebCore::SVGAElement::defaultEventHandler):
+        * svg/SVGAnimateElement.cpp:
+        (WebCore::SVGAnimateElement::calculateAnimatedValue):
+        * svg/SVGAnimationElement.cpp:
+        (WebCore::SVGAnimationElement::currentValuesForValuesAnimation):
+        * svg/SVGElement.cpp:
+        (WebCore::SVGElement::getBoundingBox):
+        * svg/SVGLinearGradientElement.cpp:
+        (WebCore::SVGLinearGradientElement::collectGradientAttributes):
+        * svg/SVGLocatable.cpp:
+        (WebCore::SVGLocatable::getTransformToElement):
+        * svg/SVGPolyElement.cpp:
+        (WebCore::SVGPolyElement::synchronizePoints):
+        (WebCore::SVGPolyElement::lookupOrCreatePointsWrapper):
+        * svg/SVGRadialGradientElement.cpp:
+        (WebCore::SVGRadialGradientElement::collectGradientAttributes):
+        * svg/SVGTextContentElement.cpp:
+        (WebCore::SVGTextContentElement::synchronizeTextLength):
+        (WebCore::SVGTextContentElement::lookupOrCreateTextLengthWrapper):
+        (WebCore::SVGTextContentElement::elementFromRenderer):
+        * svg/SVGUseElement.cpp:
+        (WebCore::SVGUseElement::toClipPath):
+        * svg/animation/SVGSMILElement.cpp:
+        (WebCore::SVGSMILElement::connectConditions):
+        (WebCore::SVGSMILElement::disconnectConditions):
+        * svg/graphics/SVGImage.cpp:
+        (WebCore::SVGImage::hasSingleSecurityOrigin):
+        (WebCore::SVGImage::setContainerSize):
+        (WebCore::SVGImage::containerSize):
+        (WebCore::SVGImage::embeddedContentBox):
+        (WebCore::SVGImage::hasRelativeWidth):
+        (WebCore::SVGImage::hasRelativeHeight):
+        (WebCore::SVGImage::computeIntrinsicDimensions):
+        (WebCore::SVGImage::startAnimation):
+        (WebCore::SVGImage::stopAnimation):
+
 2014-09-22  Simon Fraser  <simon.fra...@apple.com>
 
         Ensure that layout is up-to-date before hit-testing via RenderView

Modified: trunk/Source/WebCore/accessibility/AccessibilityRenderObject.cpp (173865 => 173866)


--- trunk/Source/WebCore/accessibility/AccessibilityRenderObject.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/accessibility/AccessibilityRenderObject.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -2885,7 +2885,7 @@
     if (!document || !document->isSVGDocument())
         return nullptr;
     
-    SVGSVGElement* rootElement = downcast<SVGDocument>(*document).rootElement();
+    SVGSVGElement* rootElement = toSVGDocument(*document).rootElement();
     if (!rootElement)
         return nullptr;
     RenderObject* rendererRoot = rootElement->renderer();

Modified: trunk/Source/WebCore/html/HTMLFrameOwnerElement.cpp (173865 => 173866)


--- trunk/Source/WebCore/html/HTMLFrameOwnerElement.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/html/HTMLFrameOwnerElement.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -115,7 +115,7 @@
 {
     Document* document = contentDocument();
     if (document && document->isSVGDocument())
-        return downcast<SVGDocument>(document);
+        return toSVGDocument(document);
     // Spec: http://www.w3.org/TR/SVG/struct.html#InterfaceGetSVGDocument
     ec = NOT_SUPPORTED_ERR;
     return nullptr;

Modified: trunk/Source/WebCore/page/EventHandler.cpp (173865 => 173866)


--- trunk/Source/WebCore/page/EventHandler.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/page/EventHandler.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -760,10 +760,10 @@
         return true;
 
     if (m_frame.document()->isSVGDocument()
-        && downcast<SVGDocument>(*m_frame.document()).zoomAndPanEnabled()) {
+        && toSVGDocument(*m_frame.document()).zoomAndPanEnabled()) {
         if (event.event().shiftKey() && singleClick) {
             m_svgPan = true;
-            downcast<SVGDocument>(*m_frame.document()).startPan(m_frame.view()->windowToContents(event.event().position()));
+            toSVGDocument(*m_frame.document()).startPan(m_frame.view()->windowToContents(event.event().position()));
             return true;
         }
     }
@@ -1893,7 +1893,7 @@
 #endif
 
     if (m_svgPan) {
-        downcast<SVGDocument>(m_frame.document())->updatePan(m_frame.view()->windowToContents(m_lastKnownMousePosition));
+        toSVGDocument(m_frame.document())->updatePan(m_frame.view()->windowToContents(m_lastKnownMousePosition));
         return true;
     }
 
@@ -2037,7 +2037,7 @@
 
     if (m_svgPan) {
         m_svgPan = false;
-        downcast<SVGDocument>(m_frame.document())->updatePan(m_frame.view()->windowToContents(m_lastKnownMousePosition));
+        toSVGDocument(m_frame.document())->updatePan(m_frame.view()->windowToContents(m_lastKnownMousePosition));
         return true;
     }
 

Modified: trunk/Source/WebCore/page/Frame.cpp (173865 => 173866)


--- trunk/Source/WebCore/page/Frame.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/page/Frame.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -968,7 +968,7 @@
     // Respect SVGs zoomAndPan="disabled" property in standalone SVG documents.
     // FIXME: How to handle compound documents + zoomAndPan="disabled"? Needs SVG WG clarification.
     if (document->isSVGDocument()) {
-        if (!downcast<SVGDocument>(*document).zoomAndPanEnabled())
+        if (!toSVGDocument(*document).zoomAndPanEnabled())
             return;
     }
 

Modified: trunk/Source/WebCore/page/FrameView.cpp (173865 => 173866)


--- trunk/Source/WebCore/page/FrameView.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/page/FrameView.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -1961,7 +1961,7 @@
     frame().document()->setCSSTarget(anchorElement);
 
     if (frame().document()->isSVGDocument()) {
-        if (SVGSVGElement* svg = downcast<SVGDocument>(*frame().document()).rootElement()) {
+        if (SVGSVGElement* svg = toSVGDocument(*frame().document()).rootElement()) {
             svg->setupInitialView(name, anchorElement);
             if (!anchorElement)
                 return true;

Modified: trunk/Source/WebCore/rendering/svg/RenderSVGBlock.h (173865 => 173866)


--- trunk/Source/WebCore/rendering/svg/RenderSVGBlock.h	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGBlock.h	2014-09-23 06:00:35 UTC (rev 173866)
@@ -32,7 +32,7 @@
 public:
     virtual LayoutRect visualOverflowRect() const override final;
 
-    SVGGraphicsElement& graphicsElement() const { return downcast<SVGGraphicsElement>(nodeForNonAnonymous()); }
+    SVGGraphicsElement& graphicsElement() const { return toSVGGraphicsElement(nodeForNonAnonymous()); }
 
 protected:
     RenderSVGBlock(SVGGraphicsElement&, PassRef<RenderStyle>);

Modified: trunk/Source/WebCore/rendering/svg/RenderSVGGradientStop.cpp (173865 => 173866)


--- trunk/Source/WebCore/rendering/svg/RenderSVGGradientStop.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGGradientStop.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -68,7 +68,7 @@
 SVGGradientElement* RenderSVGGradientStop::gradientElement()
 {
     if (element().parentElement() && isSVGGradientElement(*element().parentElement()))
-        return &downcast<SVGGradientElement>(*element().parentElement());
+        return &toSVGGradientElement(*element().parentElement());
     return nullptr;
 }
 

Modified: trunk/Source/WebCore/rendering/svg/RenderSVGInline.h (173865 => 173866)


--- trunk/Source/WebCore/rendering/svg/RenderSVGInline.h	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGInline.h	2014-09-23 06:00:35 UTC (rev 173866)
@@ -30,7 +30,7 @@
 public:
     RenderSVGInline(SVGGraphicsElement&, PassRef<RenderStyle>);
 
-    SVGGraphicsElement& graphicsElement() const { return downcast<SVGGraphicsElement>(nodeForNonAnonymous()); }
+    SVGGraphicsElement& graphicsElement() const { return toSVGGraphicsElement(nodeForNonAnonymous()); }
 
 private:
     void element() const = delete;

Modified: trunk/Source/WebCore/rendering/svg/RenderSVGResourceClipper.cpp (173865 => 173866)


--- trunk/Source/WebCore/rendering/svg/RenderSVGResourceClipper.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGResourceClipper.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -96,7 +96,7 @@
             return false;
         if (!childNode->isSVGElement() || !downcast<SVGElement>(*childNode).isSVGGraphicsElement())
             continue;
-        SVGGraphicsElement& styled = downcast<SVGGraphicsElement>(*childNode);
+        SVGGraphicsElement& styled = toSVGGraphicsElement(*childNode);
         const RenderStyle& style = renderer->style();
         if (style.display() == NONE || style.visibility() != VISIBLE)
              continue;

Modified: trunk/Source/WebCore/rendering/svg/RenderSVGResourceContainer.cpp (173865 => 173866)


--- trunk/Source/WebCore/rendering/svg/RenderSVGResourceContainer.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGResourceContainer.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -212,7 +212,7 @@
     if (!object->isSVGShape())
         return resourceTransform;
 
-    SVGGraphicsElement* element = downcast<SVGGraphicsElement>(object->node());
+    SVGGraphicsElement* element = toSVGGraphicsElement(object->node());
     AffineTransform transform = element->getScreenCTM(SVGLocatable::DisallowStyleUpdate);
     transform *= resourceTransform;
     return transform;

Modified: trunk/Source/WebCore/rendering/svg/RenderSVGShape.h (173865 => 173866)


--- trunk/Source/WebCore/rendering/svg/RenderSVGShape.h	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGShape.h	2014-09-23 06:00:35 UTC (rev 173866)
@@ -49,7 +49,7 @@
     RenderSVGShape(SVGGraphicsElement&, PassRef<RenderStyle>, Path*, bool);
     virtual ~RenderSVGShape();
 
-    SVGGraphicsElement& graphicsElement() const { return downcast<SVGGraphicsElement>(RenderSVGModelObject::element()); }
+    SVGGraphicsElement& graphicsElement() const { return toSVGGraphicsElement(RenderSVGModelObject::element()); }
 
     void setNeedsShapeUpdate() { m_needsShapeUpdate = true; }
     virtual void setNeedsBoundariesUpdate() override final { m_needsBoundariesUpdate = true; }

Modified: trunk/Source/WebCore/rendering/svg/RenderSVGTransformableContainer.h (173865 => 173866)


--- trunk/Source/WebCore/rendering/svg/RenderSVGTransformableContainer.h	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/rendering/svg/RenderSVGTransformableContainer.h	2014-09-23 06:00:35 UTC (rev 173866)
@@ -30,7 +30,7 @@
 class RenderSVGTransformableContainer final : public RenderSVGContainer {
 public:
     RenderSVGTransformableContainer(SVGGraphicsElement&, PassRef<RenderStyle>);
-    SVGGraphicsElement& graphicsElement() { return downcast<SVGGraphicsElement>(RenderSVGContainer::element()); }
+    SVGGraphicsElement& graphicsElement() { return toSVGGraphicsElement(RenderSVGContainer::element()); }
 
     virtual bool isSVGTransformableContainer() const { return true; }
     virtual const AffineTransform& localToParentTransform() const { return m_localTransform; }

Modified: trunk/Source/WebCore/rendering/svg/SVGRenderSupport.cpp (173865 => 173866)


--- trunk/Source/WebCore/rendering/svg/SVGRenderSupport.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/rendering/svg/SVGRenderSupport.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -464,7 +464,7 @@
             continue;
 
         if (ancestor->computedStyle()->svgStyle().hasMasker())
-            downcast<SVGGraphicsElement>(*ancestor).setShouldIsolateBlending(maskedAncestorShouldIsolateBlending);
+            toSVGGraphicsElement(*ancestor).setShouldIsolateBlending(maskedAncestorShouldIsolateBlending);
 
         return;
     }

Modified: trunk/Source/WebCore/rendering/svg/SVGRenderTreeAsText.cpp (173865 => 173866)


--- trunk/Source/WebCore/rendering/svg/SVGRenderTreeAsText.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/rendering/svg/SVGRenderTreeAsText.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -344,7 +344,7 @@
         writeNameValuePair(ts, "cy", element.cy().value(lengthContext));
         writeNameValuePair(ts, "r", element.r().value(lengthContext));
     } else if (svgElement.hasTagName(SVGNames::polygonTag) || svgElement.hasTagName(SVGNames::polylineTag)) {
-        const SVGPolyElement& element = downcast<SVGPolyElement>(svgElement);
+        const SVGPolyElement& element = toSVGPolyElement(svgElement);
         writeNameAndQuotedValue(ts, "points", element.pointList().valueAsString());
     } else if (isSVGPathElement(svgElement)) {
         const SVGPathElement& element = downcast<SVGPathElement>(svgElement);

Modified: trunk/Source/WebCore/rendering/svg/SVGRenderingContext.cpp (173865 => 173866)


--- trunk/Source/WebCore/rendering/svg/SVGRenderingContext.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/rendering/svg/SVGRenderingContext.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -106,7 +106,7 @@
 
 #if ENABLE(CSS_COMPOSITING)
     if (svgStyle.hasMasker() && downcast<SVGElement>(renderer.element())->isSVGGraphicsElement()) {
-        SVGGraphicsElement& graphicsElement = downcast<SVGGraphicsElement>(*renderer.element());
+        SVGGraphicsElement& graphicsElement = toSVGGraphicsElement(*renderer.element());
         isolateMaskForBlending = graphicsElement.shouldIsolateBlending();
     }
 #endif

Modified: trunk/Source/WebCore/rendering/svg/SVGResources.cpp (173865 => 173866)


--- trunk/Source/WebCore/rendering/svg/SVGResources.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/rendering/svg/SVGResources.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -144,7 +144,7 @@
     if (isSVGPatternElement(element))
         target = downcast<SVGPatternElement>(element).href();
     else if (isSVGGradientElement(element))
-        target = downcast<SVGGradientElement>(element).href();
+        target = toSVGGradientElement(element).href();
     else if (isSVGFilterElement(element))
         target = downcast<SVGFilterElement>(element).href();
     else

Modified: trunk/Source/WebCore/svg/SVGAElement.cpp (173865 => 173866)


--- trunk/Source/WebCore/svg/SVGAElement.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/svg/SVGAElement.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -161,7 +161,7 @@
             if (url[0] == '#') {
                 Element* targetElement = treeScope().getElementById(url.substringSharingImpl(1));
                 if (targetElement && isSVGSMILElement(*targetElement)) {
-                    downcast<SVGSMILElement>(*targetElement).beginByLinkActivation();
+                    toSVGSMILElement(*targetElement).beginByLinkActivation();
                     event->setDefaultHandled();
                     return;
                 }

Modified: trunk/Source/WebCore/svg/SVGAnimateElement.cpp (173865 => 173866)


--- trunk/Source/WebCore/svg/SVGAnimateElement.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/svg/SVGAnimateElement.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -110,7 +110,7 @@
     ASSERT(m_fromType->type() == m_animatedPropertyType);
     ASSERT(m_toType);
 
-    SVGAnimateElement& resultAnimationElement = downcast<SVGAnimateElement>(*resultElement);
+    SVGAnimateElement& resultAnimationElement = toSVGAnimateElement(*resultElement);
     ASSERT(resultAnimationElement.m_animatedType);
     ASSERT(resultAnimationElement.m_animatedPropertyType == m_animatedPropertyType);
 

Modified: trunk/Source/WebCore/svg/SVGAnimationElement.cpp (173865 => 173866)


--- trunk/Source/WebCore/svg/SVGAnimationElement.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/svg/SVGAnimationElement.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -508,7 +508,7 @@
 
     CalcMode calcMode = this->calcMode();
     if (hasTagName(SVGNames::animateTag) || hasTagName(SVGNames::animateColorTag)) {
-        AnimatedPropertyType attributeType = downcast<SVGAnimateElement>(*this).determineAnimatedPropertyType(targetElement());
+        AnimatedPropertyType attributeType = toSVGAnimateElement(*this).determineAnimatedPropertyType(targetElement());
         // Fall back to discrete animations for Strings.
         if (attributeType == AnimatedBoolean
             || attributeType == AnimatedEnumeration

Modified: trunk/Source/WebCore/svg/SVGElement.cpp (173865 => 173866)


--- trunk/Source/WebCore/svg/SVGElement.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/svg/SVGElement.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -460,7 +460,7 @@
 bool SVGElement::getBoundingBox(FloatRect& rect, SVGLocatable::StyleUpdateStrategy styleUpdateStrategy)
 {
     if (isSVGGraphicsElement()) {
-        rect = downcast<SVGGraphicsElement>(*this).getBBox(styleUpdateStrategy);
+        rect = toSVGGraphicsElement(*this).getBBox(styleUpdateStrategy);
         return true;
     }
     return false;

Modified: trunk/Source/WebCore/svg/SVGLinearGradientElement.cpp (173865 => 173866)


--- trunk/Source/WebCore/svg/SVGLinearGradientElement.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/svg/SVGLinearGradientElement.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -174,7 +174,7 @@
         // Respect xlink:href, take attributes from referenced element
         Node* refNode = SVGURIReference::targetElementFromIRIString(current->href(), document());
         if (refNode && isSVGGradientElement(*refNode)) {
-            current = downcast<SVGGradientElement>(refNode);
+            current = toSVGGradientElement(refNode);
 
             // Cycle detection
             if (processedGradients.contains(current))

Modified: trunk/Source/WebCore/svg/SVGLocatable.cpp (173865 => 173866)


--- trunk/Source/WebCore/svg/SVGLocatable.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/svg/SVGLocatable.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -102,7 +102,7 @@
     AffineTransform ctm = getCTM(styleUpdateStrategy);
 
     if (target && target->isSVGGraphicsElement()) {
-        AffineTransform targetCTM = downcast<SVGGraphicsElement>(*target).getCTM(styleUpdateStrategy);
+        AffineTransform targetCTM = toSVGGraphicsElement(*target).getCTM(styleUpdateStrategy);
         if (!targetCTM.isInvertible()) {
             ec = SVGException::SVG_MATRIX_NOT_INVERTABLE;
             return ctm;

Modified: trunk/Source/WebCore/svg/SVGPolyElement.cpp (173865 => 173866)


--- trunk/Source/WebCore/svg/SVGPolyElement.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/svg/SVGPolyElement.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -132,7 +132,7 @@
 void SVGPolyElement::synchronizePoints(SVGElement* contextElement)
 {
     ASSERT(contextElement);
-    SVGPolyElement& ownerType = downcast<SVGPolyElement>(*contextElement);
+    SVGPolyElement& ownerType = toSVGPolyElement(*contextElement);
     if (!ownerType.m_points.shouldSynchronize)
         return;
     ownerType.m_points.synchronize(&ownerType, pointsPropertyInfo()->attributeName, ownerType.m_points.value.valueAsString());
@@ -141,7 +141,7 @@
 PassRefPtr<SVGAnimatedProperty> SVGPolyElement::lookupOrCreatePointsWrapper(SVGElement* contextElement)
 {
     ASSERT(contextElement);
-    SVGPolyElement& ownerType = downcast<SVGPolyElement>(*contextElement);
+    SVGPolyElement& ownerType = toSVGPolyElement(*contextElement);
     return SVGAnimatedProperty::lookupOrCreateWrapper<SVGPolyElement, SVGAnimatedPointList, SVGPointList>
         (&ownerType, pointsPropertyInfo(), ownerType.m_points.value);
 }

Modified: trunk/Source/WebCore/svg/SVGRadialGradientElement.cpp (173865 => 173866)


--- trunk/Source/WebCore/svg/SVGRadialGradientElement.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/svg/SVGRadialGradientElement.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -192,7 +192,7 @@
         // Respect xlink:href, take attributes from referenced element
         Node* refNode = SVGURIReference::targetElementFromIRIString(current->href(), document());
         if (refNode && isSVGGradientElement(*refNode)) {
-            current = downcast<SVGGradientElement>(refNode);
+            current = toSVGGradientElement(refNode);
 
             // Cycle detection
             if (processedGradients.contains(current))

Modified: trunk/Source/WebCore/svg/SVGTextContentElement.cpp (173865 => 173866)


--- trunk/Source/WebCore/svg/SVGTextContentElement.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/svg/SVGTextContentElement.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -75,7 +75,7 @@
 void SVGTextContentElement::synchronizeTextLength(SVGElement* contextElement)
 {
     ASSERT(contextElement);
-    SVGTextContentElement& ownerType = downcast<SVGTextContentElement>(*contextElement);
+    SVGTextContentElement& ownerType = toSVGTextContentElement(*contextElement);
     if (!ownerType.m_textLength.shouldSynchronize)
         return;
     AtomicString value(SVGPropertyTraits<SVGLength>::toString(ownerType.m_specifiedTextLength));
@@ -85,7 +85,7 @@
 PassRefPtr<SVGAnimatedProperty> SVGTextContentElement::lookupOrCreateTextLengthWrapper(SVGElement* contextElement)
 {
     ASSERT(contextElement);
-    SVGTextContentElement& ownerType = downcast<SVGTextContentElement>(*contextElement);
+    SVGTextContentElement& ownerType = toSVGTextContentElement(*contextElement);
     return SVGAnimatedProperty::lookupOrCreateWrapper<SVGTextContentElement, SVGAnimatedLength, SVGLength>
         (&ownerType, textLengthPropertyInfo(), ownerType.m_textLength.value);
 }
@@ -299,7 +299,7 @@
     if (!element->isTextContent())
         return nullptr;
 
-    return downcast<SVGTextContentElement>(element);
+    return toSVGTextContentElement(element);
 }
 
 }

Modified: trunk/Source/WebCore/svg/SVGUseElement.cpp (173865 => 173866)


--- trunk/Source/WebCore/svg/SVGUseElement.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/svg/SVGUseElement.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -552,7 +552,7 @@
             // Spec: Indirect references are an error (14.3.5)
             document().accessSVGExtensions()->reportError("Not allowed to use indirect reference in <clip-path>");
         } else {
-            downcast<SVGGraphicsElement>(*node).toClipPath(path);
+            toSVGGraphicsElement(*node).toClipPath(path);
             // FIXME: Avoid manual resolution of x/y here. Its potentially harmful.
             SVGLengthContext lengthContext(this);
             path.translate(FloatSize(x().value(lengthContext), y().value(lengthContext)));

Modified: trunk/Source/WebCore/svg/animation/SVGSMILElement.cpp (173865 => 173866)


--- trunk/Source/WebCore/svg/animation/SVGSMILElement.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/svg/animation/SVGSMILElement.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -540,7 +540,7 @@
                 condition.m_syncbase = nullptr;
                 continue;
             }
-            downcast<SVGSMILElement>(*condition.m_syncbase).addTimeDependent(this);
+            toSVGSMILElement(*condition.m_syncbase).addTimeDependent(this);
         }
     }
 }
@@ -568,7 +568,7 @@
             condition.m_eventListener = nullptr;
         } else if (condition.m_type == Condition::Syncbase) {
             if (condition.m_syncbase)
-                downcast<SVGSMILElement>(condition.m_syncbase.get())->removeTimeDependent(this);
+                toSVGSMILElement(condition.m_syncbase.get())->removeTimeDependent(this);
         }
         condition.m_syncbase = nullptr;
     }

Modified: trunk/Source/WebCore/svg/graphics/SVGImage.cpp (173865 => 173866)


--- trunk/Source/WebCore/svg/graphics/SVGImage.cpp	2014-09-23 04:39:35 UTC (rev 173865)
+++ trunk/Source/WebCore/svg/graphics/SVGImage.cpp	2014-09-23 06:00:35 UTC (rev 173866)
@@ -68,7 +68,7 @@
     if (!m_page)
         return true;
 
-    SVGSVGElement* rootElement = downcast<SVGDocument>(m_page->mainFrame().document())->rootElement();
+    SVGSVGElement* rootElement = toSVGDocument(m_page->mainFrame().document())->rootElement();
     if (!rootElement)
         return true;
 
@@ -86,7 +86,7 @@
     if (!m_page || !usesContainerSize())
         return;
 
-    SVGSVGElement* rootElement = downcast<SVGDocument>(m_page->mainFrame().document())->rootElement();
+    SVGSVGElement* rootElement = toSVGDocument(m_page->mainFrame().document())->rootElement();
     if (!rootElement)
         return;
     RenderSVGRoot* renderer = toRenderSVGRoot(rootElement->renderer());
@@ -103,7 +103,7 @@
 {
     if (!m_page)
         return IntSize();
-    SVGSVGElement* rootElement = downcast<SVGDocument>(m_page->mainFrame().document())->rootElement();
+    SVGSVGElement* rootElement = toSVGDocument(m_page->mainFrame().document())->rootElement();
     if (!rootElement)
         return IntSize();
 
@@ -264,7 +264,7 @@
 {
     if (!m_page)
         return 0;
-    SVGSVGElement* rootElement = downcast<SVGDocument>(m_page->mainFrame().document())->rootElement();
+    SVGSVGElement* rootElement = toSVGDocument(m_page->mainFrame().document())->rootElement();
     if (!rootElement)
         return 0;
     return toRenderBox(rootElement->renderer());
@@ -281,7 +281,7 @@
 {
     if (!m_page)
         return false;
-    SVGSVGElement* rootElement = downcast<SVGDocument>(m_page->mainFrame().document())->rootElement();
+    SVGSVGElement* rootElement = toSVGDocument(m_page->mainFrame().document())->rootElement();
     if (!rootElement)
         return false;
     return rootElement->intrinsicWidth().isPercent();
@@ -291,7 +291,7 @@
 {
     if (!m_page)
         return false;
-    SVGSVGElement* rootElement = downcast<SVGDocument>(m_page->mainFrame().document())->rootElement();
+    SVGSVGElement* rootElement = toSVGDocument(m_page->mainFrame().document())->rootElement();
     if (!rootElement)
         return false;
     return rootElement->intrinsicHeight().isPercent();
@@ -301,7 +301,7 @@
 {
     if (!m_page)
         return;
-    SVGSVGElement* rootElement = downcast<SVGDocument>(m_page->mainFrame().document())->rootElement();
+    SVGSVGElement* rootElement = toSVGDocument(m_page->mainFrame().document())->rootElement();
     if (!rootElement)
         return;
 
@@ -320,7 +320,7 @@
 {
     if (!m_page)
         return;
-    SVGSVGElement* rootElement = downcast<SVGDocument>(m_page->mainFrame().document())->rootElement();
+    SVGSVGElement* rootElement = toSVGDocument(m_page->mainFrame().document())->rootElement();
     if (!rootElement)
         return;
     rootElement->unpauseAnimations();
@@ -331,7 +331,7 @@
 {
     if (!m_page)
         return;
-    SVGSVGElement* rootElement = downcast<SVGDocument>(m_page->mainFrame().document())->rootElement();
+    SVGSVGElement* rootElement = toSVGDocument(m_page->mainFrame().document())->rootElement();
     if (!rootElement)
         return;
     rootElement->pauseAnimations();
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to