Changeset 236991 in webkit
- Timestamp:
- Oct 9, 2018, 4:59:52 PM (8 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 5 edited
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/svg/dynamic-updates/SVGStopElement-dom-xml-lang-attrr-expected.txt (added)
-
LayoutTests/svg/dynamic-updates/SVGStopElement-dom-xml-lang-attrr.html (added)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/svg/SVGElement.h (modified) (1 diff)
-
Source/WebCore/svg/SVGGeometryElement.h (modified) (2 diffs)
-
Source/WebCore/svg/SVGLangSpace.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r236987 r236991 1 2018-10-09 Said Abou-Hallawa <sabouhallawa@apple.com> 2 3 REGRESSION(r234620): SVGLangSpace::svgAttributeChanged() should invalidate the renderer of the SVGGeometryElement descendant only 4 https://bugs.webkit.org/show_bug.cgi?id=190411 5 6 Reviewed by Simon Fraser. 7 8 * svg/dynamic-updates/SVGStopElement-dom-xml-lang-attrr-expected.txt: Added. 9 * svg/dynamic-updates/SVGStopElement-dom-xml-lang-attrr.html: Added. 10 1 11 2018-10-09 Chris Dumez <cdumez@apple.com> 2 12 -
trunk/Source/WebCore/ChangeLog
r236987 r236991 1 2018-10-09 Said Abou-Hallawa <sabouhallawa@apple.com> 2 3 REGRESSION(r234620): SVGLangSpace::svgAttributeChanged() should invalidate the renderer of the SVGGeometryElement descendant only 4 https://bugs.webkit.org/show_bug.cgi?id=190411 5 6 Reviewed by Simon Fraser. 7 8 Test: svg/dynamic-updates/SVGStopElement-dom-xml-lang-attrr.html 9 10 When changing the attributes of the SVGLangSpace, we should invalidate 11 the renderer of the SVGGeometryElement descendant only. Renderer of other 12 elements, like SVGStopElement, should not be invalidated because they do 13 not have geometry and they can be used as resources for drawing another 14 SVGGeometryElement. 15 16 * svg/SVGElement.h: 17 (WebCore::SVGElement::isSVGGeometryElement const): 18 * svg/SVGGeometryElement.h: 19 (isType): 20 * svg/SVGLangSpace.cpp: 21 (WebCore::SVGLangSpace::svgAttributeChanged): 22 1 23 2018-10-09 Chris Dumez <cdumez@apple.com> 2 24 -
trunk/Source/WebCore/svg/SVGElement.h
r234620 r236991 66 66 67 67 virtual bool isSVGGraphicsElement() const { return false; } 68 virtual bool isSVGGeometryElement() const { return false; } 68 69 virtual bool isFilterEffect() const { return false; } 69 70 virtual bool isGradientStop() const { return false; } -
trunk/Source/WebCore/svg/SVGGeometryElement.h
r234620 r236991 55 55 56 56 private: 57 bool isSVGGeometryElement() const override { return true; } 57 58 const SVGAttributeOwnerProxy& attributeOwnerProxy() const override { return m_attributeOwnerProxy; } 58 59 … … 65 66 66 67 } // namespace WebCore 68 69 SPECIALIZE_TYPE_TRAITS_BEGIN(WebCore::SVGGeometryElement) 70 static bool isType(const WebCore::SVGElement& element) { return element.isSVGGeometryElement(); } 71 static bool isType(const WebCore::Node& node) { return is<WebCore::SVGElement>(node) && isType(downcast<WebCore::SVGElement>(node)); } 72 SPECIALIZE_TYPE_TRAITS_END() -
trunk/Source/WebCore/svg/SVGLangSpace.cpp
r234620 r236991 25 25 #include "RenderSVGResource.h" 26 26 #include "RenderSVGShape.h" 27 #include "SVG Element.h"27 #include "SVGGeometryElement.h" 28 28 #include "XMLNames.h" 29 29 #include <wtf/NeverDestroyed.h> … … 68 68 return; 69 69 70 if (auto* renderer = downcast<RenderSVGShape>(m_contextElement.renderer())) { 71 SVGElement::InstanceInvalidationGuard guard(m_contextElement); 72 RenderSVGResource::markForLayoutAndParentResourceInvalidation(*renderer); 73 } 70 auto* renderer = m_contextElement.renderer(); 71 if (!is<RenderSVGShape>(renderer)) 72 return; 73 74 ASSERT(is<SVGGeometryElement>(m_contextElement)); 75 SVGElement::InstanceInvalidationGuard guard(m_contextElement); 76 RenderSVGResource::markForLayoutAndParentResourceInvalidation(*renderer); 74 77 } 75 78
Note:
See TracChangeset
for help on using the changeset viewer.