[webkit-changes] [WebKit/WebKit] b17ef6: Reduce use of downcast<>() in SVG code

Chris Dumez noreply at github.com
Wed Dec 20 13:01:46 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: b17ef60d82a20024e5e3ad6a1e71e1100222f6ab
      https://github.com/WebKit/WebKit/commit/b17ef60d82a20024e5e3ad6a1e71e1100222f6ab
  Author: Chris Dumez <cdumez at apple.com>
  Date:   2023-12-20 (Wed, 20 Dec 2023)

  Changed paths:
    M Source/WebCore/svg/DocumentSVG.cpp
    M Source/WebCore/svg/SVGAElement.cpp
    M Source/WebCore/svg/SVGAltGlyphDefElement.cpp
    M Source/WebCore/svg/SVGAltGlyphElement.cpp
    M Source/WebCore/svg/SVGClipPathElement.cpp
    M Source/WebCore/svg/SVGComponentTransferFunctionElement.cpp
    M Source/WebCore/svg/SVGElement.cpp
    M Source/WebCore/svg/SVGFEImageElement.cpp
    M Source/WebCore/svg/SVGFELightElement.cpp
    M Source/WebCore/svg/SVGFilterElement.cpp
    M Source/WebCore/svg/SVGFilterPrimitiveStandardAttributes.h
    M Source/WebCore/svg/SVGFontFaceElement.cpp
    M Source/WebCore/svg/SVGFontFaceFormatElement.cpp
    M Source/WebCore/svg/SVGFontFaceSrcElement.cpp
    M Source/WebCore/svg/SVGFontFaceUriElement.cpp
    M Source/WebCore/svg/SVGGeometryElement.cpp
    M Source/WebCore/svg/SVGLocatable.cpp
    M Source/WebCore/svg/SVGTextPathElement.cpp

  Log Message:
  -----------
  Reduce use of downcast<>() in SVG code
https://bugs.webkit.org/show_bug.cgi?id=266678

Reviewed by Simon Fraser.

Reduce use of downcast<>() in SVG code. Use dynamicDowncast<>() instead.

* Source/WebCore/svg/DocumentSVG.cpp:
(WebCore::DocumentSVG::rootElement):
* Source/WebCore/svg/SVGAElement.cpp:
(WebCore::SVGAElement::createElementRenderer):
(WebCore::SVGAElement::defaultEventHandler):
* Source/WebCore/svg/SVGAltGlyphDefElement.cpp:
(WebCore::SVGAltGlyphDefElement::hasValidGlyphElements const):
* Source/WebCore/svg/SVGAltGlyphElement.cpp:
(WebCore::SVGAltGlyphElement::hasValidGlyphElements const):
* Source/WebCore/svg/SVGClipPathElement.cpp:
(WebCore::SVGClipPathElement::shouldApplyPathClipping const):
* Source/WebCore/svg/SVGComponentTransferFunctionElement.cpp:
(WebCore::SVGComponentTransferFunctionElement::svgAttributeChanged):
* Source/WebCore/svg/SVGElement.cpp:
(WebCore::SVGElement::correspondingUseElement const):
(WebCore::SVGElement::childShouldCreateRenderer const):
(WebCore::SVGElement::svgAttributeChanged):
* Source/WebCore/svg/SVGFEImageElement.cpp:
(WebCore::SVGFEImageElement::buildPendingResource):
* Source/WebCore/svg/SVGFELightElement.cpp:
(WebCore::SVGFELightElement::svgAttributeChanged):
* Source/WebCore/svg/SVGFilterElement.cpp:
(WebCore::SVGFilterElement::childShouldCreateRenderer const):
* Source/WebCore/svg/SVGFilterPrimitiveStandardAttributes.h:
(isType):
* Source/WebCore/svg/SVGFontFaceElement.cpp:
(WebCore::SVGFontFaceElement::rebuildFontFace):
* Source/WebCore/svg/SVGFontFaceFormatElement.cpp:
(WebCore::SVGFontFaceFormatElement::childrenChanged):
* Source/WebCore/svg/SVGFontFaceSrcElement.cpp:
(WebCore::SVGFontFaceSrcElement::childrenChanged):
* Source/WebCore/svg/SVGFontFaceUriElement.cpp:
(WebCore::SVGFontFaceUriElement::childrenChanged):
* Source/WebCore/svg/SVGGeometryElement.cpp:
(WebCore::SVGGeometryElement::getTotalLength const):
(WebCore::SVGGeometryElement::getPointAtLength const):
(WebCore::SVGGeometryElement::isPointInFill):
(WebCore::SVGGeometryElement::isPointInStroke):
* Source/WebCore/svg/SVGLocatable.cpp:
(WebCore::toViewportElement):
(WebCore::SVGLocatable::nearestViewportElement):
(WebCore::SVGLocatable::farthestViewportElement):
(WebCore::isViewportElement): Deleted.
* Source/WebCore/svg/SVGTextPathElement.cpp:
(WebCore::SVGTextPathElement::buildPendingResource):

Canonical link: https://commits.webkit.org/272374@main




More information about the webkit-changes mailing list