WebKit Bugzilla
Attachment 346540 Details for
Bug 186751
: Remove the SVG elements' attributes macros
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Remove macro files, fix build and address some of the review comments
186751-89.patch (text/plain), 112.54 KB, created by
Said Abou-Hallawa
on 2018-08-03 12:48:45 PDT
(
hide
)
Description:
Remove macro files, fix build and address some of the review comments
Filename:
MIME Type:
Creator:
Said Abou-Hallawa
Created:
2018-08-03 12:48:45 PDT
Size:
112.54 KB
patch
obsolete
>diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index e2d2db3cad3..36d3d055b6f 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,173 @@ >+2018-08-03 Said Abou-Hallawa <sabouhallawa@apple.com> >+ >+ [89] Remove the SVG elements' attributes macros >+ https://bugs.webkit.org/show_bug.cgi?id=186751 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Remove macro files, fix build and address some of the review comments. >+ >+ * Sources.txt: >+ * WebCore.xcodeproj/project.pbxproj: >+ * rendering/svg/RenderSVGResourceMarker.cpp: >+ (WebCore::RenderSVGResourceMarker::draw): >+ * svg/SVGAElement.cpp: >+ (WebCore::SVGAElement::SVGAElement): >+ * svg/SVGAElement.h: >+ * svg/SVGAltGlyphElement.cpp: >+ (WebCore::SVGAltGlyphElement::SVGAltGlyphElement): >+ * svg/SVGAnimatedRect.h: >+ * svg/SVGAnimatedTypeAnimator.cpp: >+ (WebCore::SVGAnimatedTypeAnimator::findAnimatedPropertiesForAttributeName): >+ * svg/SVGAnimationElement.cpp: >+ (WebCore::SVGAnimationElement::SVGAnimationElement): >+ * svg/SVGAnimationElement.h: >+ * svg/SVGCircleElement.cpp: >+ (WebCore::SVGCircleElement::SVGCircleElement): >+ * svg/SVGClipPathElement.cpp: >+ (WebCore::SVGClipPathElement::SVGClipPathElement): >+ * svg/SVGClipPathElement.h: >+ * svg/SVGComponentTransferFunctionElement.h: >+ (WebCore::SVGComponentTransferFunctionElement::intercept const): >+ (WebCore::SVGComponentTransferFunctionElement::amplitude const): >+ (WebCore::SVGComponentTransferFunctionElement::exponent const): >+ (WebCore::SVGComponentTransferFunctionElement::offset const): >+ * svg/SVGCursorElement.cpp: >+ (WebCore::SVGCursorElement::SVGCursorElement): >+ * svg/SVGCursorElement.h: >+ * svg/SVGDefsElement.cpp: >+ (WebCore::SVGDefsElement::SVGDefsElement): >+ * svg/SVGElement.cpp: >+ (WebCore::SVGElement::SVGElement): >+ (WebCore::SVGElement::synchronizeAnimatedSVGAttribute const): >+ * svg/SVGEllipseElement.cpp: >+ (WebCore::SVGEllipseElement::SVGEllipseElement): >+ * svg/SVGExternalResourcesRequired.cpp: >+ (WebCore::SVGExternalResourcesRequired::SVGExternalResourcesRequired): >+ (WebCore::SVGExternalResourcesRequired::svgAttributeChanged): >+ (WebCore::SVGExternalResourcesRequired::dispatchLoadEvent): >+ * svg/SVGExternalResourcesRequired.h: >+ * svg/SVGFEComponentTransferElement.cpp: >+ * svg/SVGFECompositeElement.cpp: >+ (WebCore::SVGFECompositeElement::SVGFECompositeElement): >+ * svg/SVGFEConvolveMatrixElement.cpp: >+ (WebCore::SVGFEConvolveMatrixElement::parseAttribute): >+ * svg/SVGFEImageElement.cpp: >+ (WebCore::SVGFEImageElement::SVGFEImageElement): >+ * svg/SVGFEImageElement.h: >+ * svg/SVGFilterElement.cpp: >+ (WebCore::SVGFilterElement::SVGFilterElement): >+ (WebCore::SVGFilterElement::parseAttribute): >+ * svg/SVGFilterElement.h: >+ * svg/SVGFilterPrimitiveStandardAttributes.cpp: >+ (WebCore::SVGFilterPrimitiveStandardAttributes::isSupportedAttribute): Deleted. >+ * svg/SVGFitToViewBox.cpp: >+ (WebCore::SVGFitToViewBox::SVGFitToViewBox): >+ (WebCore::SVGFitToViewBox::parseViewBox): >+ * svg/SVGFitToViewBox.h: >+ * svg/SVGFontElement.cpp: >+ (WebCore::SVGFontElement::SVGFontElement): >+ * svg/SVGForeignObjectElement.cpp: >+ (WebCore::SVGForeignObjectElement::SVGForeignObjectElement): >+ * svg/SVGGElement.cpp: >+ (WebCore::SVGGElement::SVGGElement): >+ * svg/SVGGeometryElement.cpp: >+ (WebCore::SVGGeometryElement::svgAttributeChanged): >+ * svg/SVGGlyphRefElement.cpp: >+ (WebCore::SVGGlyphRefElement::SVGGlyphRefElement): >+ * svg/SVGGlyphRefElement.h: >+ * svg/SVGGradientElement.cpp: >+ (WebCore::SVGGradientElement::SVGGradientElement): >+ * svg/SVGGradientElement.h: >+ * svg/SVGGraphicsElement.cpp: >+ (WebCore::SVGGraphicsElement::SVGGraphicsElement): >+ * svg/SVGImageElement.cpp: >+ (WebCore::SVGImageElement::SVGImageElement): >+ (WebCore::SVGImageElement::svgAttributeChanged): >+ * svg/SVGImageLoader.cpp: >+ (WebCore::SVGImageLoader::dispatchLoadEvent): >+ * svg/SVGLineElement.cpp: >+ (WebCore::SVGLineElement::SVGLineElement): >+ * svg/SVGMPathElement.cpp: >+ (WebCore::SVGMPathElement::SVGMPathElement): >+ * svg/SVGMPathElement.h: >+ * svg/SVGMarkerElement.cpp: >+ (WebCore::SVGMarkerElement::SVGMarkerElement): >+ (WebCore::SVGMarkerElement::svgAttributeChanged): >+ * svg/SVGMaskElement.cpp: >+ (WebCore::SVGMaskElement::SVGMaskElement): >+ * svg/SVGMaskElement.h: >+ * svg/SVGPathElement.cpp: >+ (WebCore::SVGPathElement::SVGPathElement): >+ (WebCore::SVGPathElement::pathByteStream const): >+ * svg/SVGPathSegListValues.h: >+ (WebCore::SVGPropertyTraits<SVGPathSegListValues>::toString): >+ * svg/SVGPathSegWithContext.h: >+ * svg/SVGPatternElement.cpp: >+ (WebCore::SVGPatternElement::SVGPatternElement): >+ (WebCore::SVGPatternElement::svgAttributeChanged): >+ * svg/SVGPatternElement.h: >+ * svg/SVGPolyElement.cpp: >+ (WebCore::SVGPolyElement::SVGPolyElement): >+ * svg/SVGPolyElement.h: >+ * svg/SVGPreserveAspectRatioValue.cpp: >+ (WebCore::SVGPreserveAspectRatioValue::transformRect const): >+ * svg/SVGPreserveAspectRatioValue.h: >+ * svg/SVGRectElement.cpp: >+ (WebCore::SVGRectElement::SVGRectElement): >+ * svg/SVGSVGElement.cpp: >+ (WebCore::SVGSVGElement::SVGSVGElement): >+ (WebCore::SVGSVGElement::svgAttributeChanged): >+ (WebCore::SVGSVGElement::inheritViewAttributes): >+ * svg/SVGScriptElement.cpp: >+ (WebCore::SVGScriptElement::SVGScriptElement): >+ (WebCore::SVGScriptElement::svgAttributeChanged): >+ * svg/SVGScriptElement.h: >+ * svg/SVGSwitchElement.cpp: >+ (WebCore::SVGSwitchElement::SVGSwitchElement): >+ * svg/SVGSymbolElement.cpp: >+ (WebCore::SVGSymbolElement::SVGSymbolElement): >+ (WebCore::SVGSymbolElement::svgAttributeChanged): >+ * svg/SVGTRefElement.cpp: >+ (WebCore::SVGTRefElement::SVGTRefElement): >+ * svg/SVGTests.cpp: >+ (WebCore::SVGTests::requiredFeatures): >+ (WebCore::SVGTests::requiredExtensions): >+ (WebCore::SVGTests::systemLanguage): >+ * svg/SVGTests.h: >+ * svg/SVGTextContentElement.cpp: >+ (WebCore::SVGTextContentElement::SVGTextContentElement): >+ * svg/SVGTextContentElement.h: >+ * svg/SVGTextPathElement.cpp: >+ (WebCore::SVGTextPathElement::SVGTextPathElement): >+ * svg/SVGURIReference.cpp: >+ (WebCore::SVGURIReference::SVGURIReference): >+ * svg/SVGURIReference.h: >+ * svg/SVGUseElement.cpp: >+ (WebCore::SVGUseElement::SVGUseElement): >+ (WebCore::SVGUseElement::transferSizeAttributesToTargetClone const): >+ * svg/SVGValue.h: >+ * svg/SVGViewElement.cpp: >+ (WebCore::SVGViewElement::SVGViewElement): >+ * svg/SVGViewElement.h: >+ * svg/SVGViewSpec.cpp: >+ (WebCore::SVGViewSpec::SVGViewSpec): >+ * svg/SVGZoomAndPan.cpp: >+ (WebCore::SVGZoomAndPan::SVGZoomAndPan): >+ * svg/SVGZoomAndPan.h: >+ * svg/properties/SVGAnimatedEnumerationPropertyTearOff.h: >+ * svg/properties/SVGAnimatedPathSegListPropertyTearOff.cpp: >+ (WebCore::SVGAnimatedPathSegListPropertyTearOff::animValDidChange): >+ * svg/properties/SVGAnimatedProperty.h: >+ * svg/properties/SVGAnimatedPropertyMacros.h: Removed. >+ * svg/properties/SVGAttributeAccessor.h: >+ * svg/properties/SVGAttributeRegistry.h: >+ (WebCore::SVGAttributeRegistry::isKnownAttribute const): >+ * svg/properties/SVGAttributeToPropertyMap.cpp: Removed. >+ * svg/properties/SVGAttributeToPropertyMap.h: Removed. >+ * svg/properties/SVGPropertyInfo.cpp: Removed. >+ * svg/properties/SVGPropertyInfo.h: Removed. >+ > 2018-08-02 Said Abou-Hallawa <sabouhallawa@apple.com> > > [88] Remove the SVG elements' attributes macros >diff --git a/Source/WebCore/Sources.txt b/Source/WebCore/Sources.txt >index ccaccff7d53..e11c72eccc3 100644 >--- a/Source/WebCore/Sources.txt >+++ b/Source/WebCore/Sources.txt >@@ -2272,8 +2272,6 @@ svg/graphics/filters/SVGFilterBuilder.cpp > > svg/properties/SVGAnimatedPathSegListPropertyTearOff.cpp > svg/properties/SVGAnimatedProperty.cpp >-svg/properties/SVGAttributeToPropertyMap.cpp >-svg/properties/SVGPropertyInfo.cpp > > workers/AbstractWorker.cpp > workers/DedicatedWorkerGlobalScope.cpp >diff --git a/Source/WebCore/WebCore.xcodeproj/project.pbxproj b/Source/WebCore/WebCore.xcodeproj/project.pbxproj >index 11e66c93da6..f9c50dd6566 100644 >--- a/Source/WebCore/WebCore.xcodeproj/project.pbxproj >+++ b/Source/WebCore/WebCore.xcodeproj/project.pbxproj >@@ -232,7 +232,6 @@ > 081668D4125603BF006F25DE /* SVGTextChunkBuilder.h in Headers */ = {isa = PBXBuildFile; fileRef = 081668D2125603BF006F25DE /* SVGTextChunkBuilder.h */; }; > 081668DA125603D5006F25DE /* SVGTextLayoutEngine.h in Headers */ = {isa = PBXBuildFile; fileRef = 081668D8125603D5006F25DE /* SVGTextLayoutEngine.h */; }; > 081AA8DA1111237E002AB06E /* SVGElementRareData.h in Headers */ = {isa = PBXBuildFile; fileRef = 081AA8D91111237E002AB06E /* SVGElementRareData.h */; }; >- 081DD49C13BA1A6000DC7627 /* SVGPropertyInfo.h in Headers */ = {isa = PBXBuildFile; fileRef = 081DD49B13BA1A6000DC7627 /* SVGPropertyInfo.h */; settings = {ATTRIBUTES = (Private, ); }; }; > 081EBF3B0FD34F4100DA7559 /* SVGFilterBuilder.h in Headers */ = {isa = PBXBuildFile; fileRef = 081EBF390FD34F4100DA7559 /* SVGFilterBuilder.h */; }; > 0823D159127AD6AC000EBC95 /* SVGAnimatedInteger.h in Headers */ = {isa = PBXBuildFile; fileRef = 0823D158127AD6AC000EBC95 /* SVGAnimatedInteger.h */; }; > 08250939128BD4D800E2ED8E /* SVGAnimatedTransformList.h in Headers */ = {isa = PBXBuildFile; fileRef = 08250938128BD4D800E2ED8E /* SVGAnimatedTransformList.h */; }; >@@ -265,7 +264,6 @@ > 0885068011DA045B00182B98 /* PaintPhase.h in Headers */ = {isa = PBXBuildFile; fileRef = 0885067E11DA045B00182B98 /* PaintPhase.h */; settings = {ATTRIBUTES = (Private, ); }; }; > 088A0E04126EF1DB00978F7A /* SVGAnimatedListPropertyTearOff.h in Headers */ = {isa = PBXBuildFile; fileRef = 088A0DFB126EF1DB00978F7A /* SVGAnimatedListPropertyTearOff.h */; }; > 088A0E06126EF1DB00978F7A /* SVGAnimatedPropertyDescription.h in Headers */ = {isa = PBXBuildFile; fileRef = 088A0DFD126EF1DB00978F7A /* SVGAnimatedPropertyDescription.h */; settings = {ATTRIBUTES = (Private, ); }; }; >- 088A0E07126EF1DB00978F7A /* SVGAnimatedPropertyMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 088A0DFE126EF1DB00978F7A /* SVGAnimatedPropertyMacros.h */; settings = {ATTRIBUTES = (Private, ); }; }; > 088A0E08126EF1DB00978F7A /* SVGAnimatedPropertyTearOff.h in Headers */ = {isa = PBXBuildFile; fileRef = 088A0DFF126EF1DB00978F7A /* SVGAnimatedPropertyTearOff.h */; }; > 088A0E09126EF1DB00978F7A /* SVGListPropertyTearOff.h in Headers */ = {isa = PBXBuildFile; fileRef = 088A0E00126EF1DB00978F7A /* SVGListPropertyTearOff.h */; }; > 088A0E0A126EF1DB00978F7A /* SVGProperty.h in Headers */ = {isa = PBXBuildFile; fileRef = 088A0E01126EF1DB00978F7A /* SVGProperty.h */; settings = {ATTRIBUTES = (Private, ); }; }; >@@ -291,7 +289,6 @@ > 08F2F00A1213E61700DCEC48 /* RenderImageResource.h in Headers */ = {isa = PBXBuildFile; fileRef = 08F2F0081213E61700DCEC48 /* RenderImageResource.h */; settings = {ATTRIBUTES = (Private, ); }; }; > 08F859D51463F9CD0067D933 /* SVGImageCache.h in Headers */ = {isa = PBXBuildFile; fileRef = 08F859D31463F9CD0067D933 /* SVGImageCache.h */; settings = {ATTRIBUTES = (Private, ); }; }; > 08F859D51463F9CD0067D934 /* SVGImageForContainer.h in Headers */ = {isa = PBXBuildFile; fileRef = 08F859D31463F9CD0067D934 /* SVGImageForContainer.h */; }; >- 08FB3F8413BC754C0099FC18 /* SVGAttributeToPropertyMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 08FB3F8313BC754C0099FC18 /* SVGAttributeToPropertyMap.h */; settings = {ATTRIBUTES = (Private, ); }; }; > 08FE0BC5127E2AC1000C4FB5 /* SVGAnimatedPreserveAspectRatio.h in Headers */ = {isa = PBXBuildFile; fileRef = 08FE0BC4127E2AC1000C4FB5 /* SVGAnimatedPreserveAspectRatio.h */; }; > 0AFDAC3D10F5448C00E1F3D2 /* PluginViewBase.h in Headers */ = {isa = PBXBuildFile; fileRef = 0AFDAC3C10F5448C00E1F3D2 /* PluginViewBase.h */; settings = {ATTRIBUTES = (Private, ); }; }; > 0B90561A0F2578BF0095FF6A /* DocumentThreadableLoader.h in Headers */ = {isa = PBXBuildFile; fileRef = 0B9056160F2578BE0095FF6A /* DocumentThreadableLoader.h */; settings = {ATTRIBUTES = (); }; }; >@@ -5452,7 +5449,6 @@ > 081668D7125603D5006F25DE /* SVGTextLayoutEngine.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SVGTextLayoutEngine.cpp; sourceTree = "<group>"; }; > 081668D8125603D5006F25DE /* SVGTextLayoutEngine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGTextLayoutEngine.h; sourceTree = "<group>"; }; > 081AA8D91111237E002AB06E /* SVGElementRareData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGElementRareData.h; sourceTree = "<group>"; }; >- 081DD49B13BA1A6000DC7627 /* SVGPropertyInfo.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGPropertyInfo.h; sourceTree = "<group>"; }; > 081EBF380FD34F4100DA7559 /* SVGFilterBuilder.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SVGFilterBuilder.cpp; sourceTree = "<group>"; }; > 081EBF390FD34F4100DA7559 /* SVGFilterBuilder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGFilterBuilder.h; sourceTree = "<group>"; }; > 0823D158127AD6AC000EBC95 /* SVGAnimatedInteger.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGAnimatedInteger.h; sourceTree = "<group>"; }; >@@ -5501,7 +5497,6 @@ > 088A0DFB126EF1DB00978F7A /* SVGAnimatedListPropertyTearOff.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGAnimatedListPropertyTearOff.h; sourceTree = "<group>"; }; > 088A0DFC126EF1DB00978F7A /* SVGAnimatedProperty.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGAnimatedProperty.h; sourceTree = "<group>"; }; > 088A0DFD126EF1DB00978F7A /* SVGAnimatedPropertyDescription.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGAnimatedPropertyDescription.h; sourceTree = "<group>"; }; >- 088A0DFE126EF1DB00978F7A /* SVGAnimatedPropertyMacros.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGAnimatedPropertyMacros.h; sourceTree = "<group>"; }; > 088A0DFF126EF1DB00978F7A /* SVGAnimatedPropertyTearOff.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGAnimatedPropertyTearOff.h; sourceTree = "<group>"; }; > 088A0E00126EF1DB00978F7A /* SVGListPropertyTearOff.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGListPropertyTearOff.h; sourceTree = "<group>"; }; > 088A0E01126EF1DB00978F7A /* SVGProperty.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGProperty.h; sourceTree = "<group>"; }; >@@ -5535,8 +5530,6 @@ > 08F859D21463F9CD0067D934 /* SVGImageForContainer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SVGImageForContainer.cpp; sourceTree = "<group>"; }; > 08F859D31463F9CD0067D933 /* SVGImageCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGImageCache.h; sourceTree = "<group>"; }; > 08F859D31463F9CD0067D934 /* SVGImageForContainer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGImageForContainer.h; sourceTree = "<group>"; }; >- 08FB17C013BC7E9100040086 /* SVGAttributeToPropertyMap.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SVGAttributeToPropertyMap.cpp; sourceTree = "<group>"; }; >- 08FB3F8313BC754C0099FC18 /* SVGAttributeToPropertyMap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGAttributeToPropertyMap.h; sourceTree = "<group>"; }; > 08FE0BC4127E2AC1000C4FB5 /* SVGAnimatedPreserveAspectRatio.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGAnimatedPreserveAspectRatio.h; sourceTree = "<group>"; }; > 0AFDAC3C10F5448C00E1F3D2 /* PluginViewBase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PluginViewBase.h; sourceTree = "<group>"; }; > 0B8C56D30F28627F000502E1 /* HTTPHeaderMap.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = HTTPHeaderMap.cpp; sourceTree = "<group>"; }; >@@ -12542,7 +12535,6 @@ > B51A2F4017D7D5DA0072517A /* ImageQualityController.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ImageQualityController.cpp; sourceTree = "<group>"; }; > B5320D69122A24E9002D1440 /* FontPlatformData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FontPlatformData.h; sourceTree = "<group>"; }; > B5320D6A122A24E9002D1440 /* FontPlatformDataCocoa.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = FontPlatformDataCocoa.mm; sourceTree = "<group>"; }; >- B543B85617EB758F003BE93A /* SVGPropertyInfo.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SVGPropertyInfo.cpp; sourceTree = "<group>"; }; > B562DB5E17D3CD560010AF96 /* HTMLElementTypeHelpers.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = HTMLElementTypeHelpers.h; sourceTree = "<group>"; }; > B562DB5F17D3CD560010AF96 /* SVGElementTypeHelpers.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SVGElementTypeHelpers.h; sourceTree = "<group>"; }; > B56576E417DA599F00A56BDC /* JSMainThreadExecStateInstrumentation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSMainThreadExecStateInstrumentation.h; sourceTree = "<group>"; }; >@@ -15464,7 +15456,6 @@ > 836FBCEB178C117F00B21A15 /* SVGAnimatedProperty.cpp */, > 088A0DFC126EF1DB00978F7A /* SVGAnimatedProperty.h */, > 088A0DFD126EF1DB00978F7A /* SVGAnimatedPropertyDescription.h */, >- 088A0DFE126EF1DB00978F7A /* SVGAnimatedPropertyMacros.h */, > 088A0DFF126EF1DB00978F7A /* SVGAnimatedPropertyTearOff.h */, > 55FA7FFE21110E6E005AEFE7 /* SVGAnimatedPropertyType.h */, > 08525E621278C00100A84778 /* SVGAnimatedStaticPropertyTearOff.h */, >@@ -15473,14 +15464,10 @@ > 55FA7FF4210FB688005AEFE7 /* SVGAttributeAccessor.h */, > 55FA7FF9210FDB34005AEFE7 /* SVGAttributeOwnerProxy.h */, > 55FA7FF6210FBE3E005AEFE7 /* SVGAttributeRegistry.h */, >- 08FB17C013BC7E9100040086 /* SVGAttributeToPropertyMap.cpp */, >- 08FB3F8313BC754C0099FC18 /* SVGAttributeToPropertyMap.h */, > 0810764312828556007C63BA /* SVGListProperty.h */, > 088A0E00126EF1DB00978F7A /* SVGListPropertyTearOff.h */, > 08CA3D4312894A3800FFF260 /* SVGMatrixTearOff.h */, > 088A0E01126EF1DB00978F7A /* SVGProperty.h */, >- B543B85617EB758F003BE93A /* SVGPropertyInfo.cpp */, >- 081DD49B13BA1A6000DC7627 /* SVGPropertyInfo.h */, > 088A0E02126EF1DB00978F7A /* SVGPropertyTearOff.h */, > 088A0E03126EF1DB00978F7A /* SVGPropertyTraits.h */, > 0880F70D1282B46D00948505 /* SVGStaticListPropertyTearOff.h */, >@@ -28336,7 +28323,6 @@ > CD19FEA81F573972000C42FB /* ImageDecoder.h in Headers */, > CD19FEAE1F574B6D000C42FB /* ImageDecoderAVFObjC.h in Headers */, > 555B87ED1CAAF0AB00349425 /* ImageDecoderCG.h in Headers */, >- 55FA8001211113EE005AEFE7 /* SVGAnimatedProperty.h in Headers */, > 97205AB61239291000B17380 /* ImageDocument.h in Headers */, > 5576A5651D88A70800CCC04C /* ImageFrame.h in Headers */, > F55B3DC21251F12D003EF269 /* ImageInputType.h in Headers */, >@@ -28884,7 +28870,6 @@ > 31078CCA1880AACE008099DC /* JSOESTextureHalfFloatLinear.h in Headers */, > 77A17AA712F28B2A004E02F6 /* JSOESVertexArrayObject.h in Headers */, > FDF6BAF9134A4C9800822920 /* JSOfflineAudioCompletionEvent.h in Headers */, >- 55FA7FFB2110ECD7005AEFE7 /* SVGZoomAndPanType.h in Headers */, > FDA9326716703BA9008982DC /* JSOfflineAudioContext.h in Headers */, > 314877E61FAAB02500C05759 /* JSOffscreenCanvas.h in Headers */, > 3140C5271FDF558200D2A873 /* JSOffscreenCanvasRenderingContext2D.h in Headers */, >@@ -29515,7 +29500,6 @@ > 07D6A4F41BED5F8800174146 /* MockRealtimeAudioSource.h in Headers */, > 07D6A4F01BECF2D200174146 /* MockRealtimeMediaSource.h in Headers */, > 4A0FFA9E1AAF5E7E0062803B /* MockRealtimeMediaSourceCenter.h in Headers */, >- 55FA7FF5210FB6B1005AEFE7 /* SVGAttributeAccessor.h in Headers */, > 07EE76EC1BE96DB000F89133 /* MockRealtimeVideoSource.h in Headers */, > 07EE76EF1BEA619800F89133 /* MockRealtimeVideoSourceMac.h in Headers */, > CDF2B0171820540700F2B424 /* MockSourceBufferPrivate.h in Headers */, >@@ -29558,7 +29542,6 @@ > 8A309C9F123950BE00CB9204 /* NestingLevelIncrementer.h in Headers */, > 656D37430ADBA5DE00A4554D /* NetscapePlugInStreamLoader.h in Headers */, > A19D934B1AA11B1E00B46C24 /* NetworkExtensionContentFilter.h in Headers */, >- 55FA7FF7210FBE3E005AEFE7 /* SVGAttributeRegistry.h in Headers */, > 628D214C12131ED10055DCFC /* NetworkingContext.h in Headers */, > 416D75A220C651A500D02D2C /* NetworkLoadInformation.h in Headers */, > 8A81BF8511DCFD9000DA2B98 /* NetworkLoadMetrics.h in Headers */, >@@ -30391,7 +30374,6 @@ > A8EA800A0A19516E00A8EF5F /* StyleSheetList.h in Headers */, > BC5EB5E50E81BF6D00B25965 /* StyleSurroundData.h in Headers */, > BC5EB8100E81F2CE00B25965 /* StyleTransformData.h in Headers */, >- 55FA7FFF21110E6E005AEFE7 /* SVGAnimatedPropertyType.h in Headers */, > E4DEAA1817A93DC3000E0430 /* StyleTreeResolver.h in Headers */, > E42E76DC1C7AF77600E3614D /* StyleUpdate.h in Headers */, > E48137B91DB3B526005C59BF /* StyleValidity.h in Headers */, >@@ -30432,9 +30414,10 @@ > 089A8E07128D8B3D00E7A534 /* SVGAnimatedPathSegListPropertyTearOff.h in Headers */, > 43B9336913B261B1004584BF /* SVGAnimatedPointList.h in Headers */, > 08FE0BC5127E2AC1000C4FB5 /* SVGAnimatedPreserveAspectRatio.h in Headers */, >+ 55FA8001211113EE005AEFE7 /* SVGAnimatedProperty.h in Headers */, > 088A0E06126EF1DB00978F7A /* SVGAnimatedPropertyDescription.h in Headers */, >- 088A0E07126EF1DB00978F7A /* SVGAnimatedPropertyMacros.h in Headers */, > 088A0E08126EF1DB00978F7A /* SVGAnimatedPropertyTearOff.h in Headers */, >+ 55FA7FFF21110E6E005AEFE7 /* SVGAnimatedPropertyType.h in Headers */, > 08C859C01274575400A5728D /* SVGAnimatedRect.h in Headers */, > 08525E631278C00100A84778 /* SVGAnimatedStaticPropertyTearOff.h in Headers */, > 084DB59B128008CC002A6D64 /* SVGAnimatedString.h in Headers */, >@@ -30448,7 +30431,9 @@ > B22279950D00BF220071B782 /* SVGAnimateTransformElement.h in Headers */, > B22279980D00BF220071B782 /* SVGAnimationElement.h in Headers */, > 439D334513A6911C00C20F4F /* SVGAnimatorFactory.h in Headers */, >- 08FB3F8413BC754C0099FC18 /* SVGAttributeToPropertyMap.h in Headers */, >+ 55FA7FF0210FA386005AEFE7 /* SVGAttribute.h in Headers */, >+ 55FA7FF5210FB6B1005AEFE7 /* SVGAttributeAccessor.h in Headers */, >+ 55FA7FF7210FBE3E005AEFE7 /* SVGAttributeRegistry.h in Headers */, > B222799C0D00BF220071B782 /* SVGCircleElement.h in Headers */, > B222799F0D00BF220071B782 /* SVGClipPathElement.h in Headers */, > B22279A50D00BF220071B782 /* SVGComponentTransferFunctionElement.h in Headers */, >@@ -30591,7 +30576,6 @@ > B2227A940D00BF220071B782 /* SVGPolylineElement.h in Headers */, > B2227A970D00BF220071B782 /* SVGPreserveAspectRatio.h in Headers */, > 088A0E0A126EF1DB00978F7A /* SVGProperty.h in Headers */, >- 081DD49C13BA1A6000DC7627 /* SVGPropertyInfo.h in Headers */, > 088A0E0B126EF1DB00978F7A /* SVGPropertyTearOff.h in Headers */, > 088A0E0C126EF1DB00978F7A /* SVGPropertyTraits.h in Headers */, > B2227A9A0D00BF220071B782 /* SVGRadialGradientElement.h in Headers */, >@@ -30652,6 +30636,7 @@ > B2227AF30D00BF220071B782 /* SVGViewSpec.h in Headers */, > 8485228B1190173C006EDC7F /* SVGVKernElement.h in Headers */, > B2227AF60D00BF220071B782 /* SVGZoomAndPan.h in Headers */, >+ 55FA7FFB2110ECD7005AEFE7 /* SVGZoomAndPanType.h in Headers */, > B2E4EC980D00C22B00432643 /* SVGZoomEvent.h in Headers */, > 46ECB6381FD0A3C80088E5AD /* SWClientConnection.h in Headers */, > 46658DC91FA24B8700F7DD54 /* SWContextManager.h in Headers */, >@@ -30710,7 +30695,6 @@ > E4C91A0E1802343100A17F6D /* TextPaintStyle.h in Headers */, > 93F198F608245E59001E9ABC /* TextResourceDecoder.h in Headers */, > A824B4650E2EF2EA0081A7B7 /* TextRun.h in Headers */, >- 55FA7FF0210FA386005AEFE7 /* SVGAttribute.h in Headers */, > 448B1B7A0F3A2F9B0047A9E2 /* TextSizeAdjustment.h in Headers */, > 9759E94014EF1CF80026A2DD /* TextTrack.h in Headers */, > 9759E94314EF1CF80026A2DD /* TextTrackCue.h in Headers */, >diff --git a/Source/WebCore/rendering/svg/RenderSVGResourceMarker.cpp b/Source/WebCore/rendering/svg/RenderSVGResourceMarker.cpp >index 5948119862e..0acf8183a08 100644 >--- a/Source/WebCore/rendering/svg/RenderSVGResourceMarker.cpp >+++ b/Source/WebCore/rendering/svg/RenderSVGResourceMarker.cpp >@@ -115,7 +115,7 @@ AffineTransform RenderSVGResourceMarker::markerTransformation(const FloatPoint& > void RenderSVGResourceMarker::draw(PaintInfo& paintInfo, const AffineTransform& transform) > { > // An empty viewBox disables rendering. >- if (markerElement().hasAttribute(SVGNames::viewBoxAttr) && markerElement().viewBoxIsValid() && markerElement().viewBox().isEmpty()) >+ if (markerElement().hasAttribute(SVGNames::viewBoxAttr) && markerElement().hasEmptyViewBox()) > return; > > PaintInfo info(paintInfo); >diff --git a/Source/WebCore/svg/SVGAElement.cpp b/Source/WebCore/svg/SVGAElement.cpp >index e41f92dee05..cc3c09f763b 100644 >--- a/Source/WebCore/svg/SVGAElement.cpp >+++ b/Source/WebCore/svg/SVGAElement.cpp >@@ -48,8 +48,8 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGAElement); > > inline SVGAElement::SVGAElement(const QualifiedName& tagName, Document& document) > : SVGGraphicsElement(tagName, document) >- , SVGURIReference(*this) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGURIReference(this) > { > ASSERT(hasTagName(SVGNames::aTag)); > registerAttributes(); >diff --git a/Source/WebCore/svg/SVGAElement.h b/Source/WebCore/svg/SVGAElement.h >index e5ba4e34649..348f5cb825a 100644 >--- a/Source/WebCore/svg/SVGAElement.h >+++ b/Source/WebCore/svg/SVGAElement.h >@@ -22,24 +22,24 @@ > > #pragma once > >-#include "SVGAnimatedBoolean.h" > #include "SVGExternalResourcesRequired.h" > #include "SVGGraphicsElement.h" > #include "SVGURIReference.h" > > namespace WebCore { > >-class SVGAElement final : public SVGGraphicsElement, public SVGURIReference, public SVGExternalResourcesRequired { >+class SVGAElement final : public SVGGraphicsElement, public SVGExternalResourcesRequired, public SVGURIReference { > WTF_MAKE_ISO_ALLOCATED(SVGAElement); > public: > static Ref<SVGAElement> create(const QualifiedName&, Document&); > >- auto targetAnimated() { return m_target.animatedProperty(); } >+ String target() const final { return m_target.currentValue(); } >+ RefPtr<SVGAnimatedString> targetAnimated() { return m_target.animatedProperty(); } > > private: > SVGAElement(const QualifiedName&, Document&); > >- using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGAElement, SVGGraphicsElement, SVGURIReference, SVGExternalResourcesRequired>; >+ using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGAElement, SVGGraphicsElement, SVGExternalResourcesRequired, SVGURIReference>; > static AttributeOwnerProxy::AttributeRegistry& attributeRegistry() { return AttributeOwnerProxy::attributeRegistry(); } > static void registerAttributes(); > >@@ -52,7 +52,6 @@ private: > > bool isValid() const final { return SVGTests::isValid(); } > String title() const final; >- String target() const final { return svgTarget(); } > void defaultEventHandler(Event&) final; > > bool supportsFocus() const final; >diff --git a/Source/WebCore/svg/SVGAltGlyphElement.cpp b/Source/WebCore/svg/SVGAltGlyphElement.cpp >index eb287c792db..782b245ad1b 100644 >--- a/Source/WebCore/svg/SVGAltGlyphElement.cpp >+++ b/Source/WebCore/svg/SVGAltGlyphElement.cpp >@@ -39,7 +39,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGAltGlyphElement); > > inline SVGAltGlyphElement::SVGAltGlyphElement(const QualifiedName& tagName, Document& document) > : SVGTextPositioningElement(tagName, document) >- , SVGURIReference(*this) >+ , SVGURIReference(this) > { > ASSERT(hasTagName(SVGNames::altGlyphTag)); > } >diff --git a/Source/WebCore/svg/SVGAnimatedRect.h b/Source/WebCore/svg/SVGAnimatedRect.h >index 8dc73daf76d..8b26dce4f4c 100644 >--- a/Source/WebCore/svg/SVGAnimatedRect.h >+++ b/Source/WebCore/svg/SVGAnimatedRect.h >@@ -22,6 +22,7 @@ > > #include "SVGAnimatedPropertyTearOff.h" > #include "SVGAnimatedTypeAnimator.h" >+#include "SVGAttributeAccessor.h" > #include "SVGRect.h" > > namespace WebCore { >diff --git a/Source/WebCore/svg/SVGAnimatedTypeAnimator.cpp b/Source/WebCore/svg/SVGAnimatedTypeAnimator.cpp >index cddb191f6e2..dcf9c44b6cb 100644 >--- a/Source/WebCore/svg/SVGAnimatedTypeAnimator.cpp >+++ b/Source/WebCore/svg/SVGAnimatedTypeAnimator.cpp >@@ -22,7 +22,6 @@ > #include "config.h" > #include "SVGAnimatedTypeAnimator.h" > >-#include "SVGAttributeToPropertyMap.h" > #include "SVGElement.h" > > namespace WebCore { >@@ -56,16 +55,14 @@ SVGElementAnimatedPropertyList SVGAnimatedTypeAnimator::findAnimatedPropertiesFo > if (!SVGAnimatedType::supportsAnimVal(m_type)) > return result; > >- auto& propertyMap = targetElement.localAttributeToPropertyMap(); >- auto targetProperties = propertyMap.properties(targetElement, attributeName); >- >+ auto targetProperties = targetElement.lookupOrCreateAnimatedProperties(attributeName); > if (targetProperties.isEmpty()) > return result; > > result.append(SVGElementAnimatedProperties { &targetElement, WTFMove(targetProperties) }); > > for (SVGElement* instance : targetElement.instances()) >- result.append(SVGElementAnimatedProperties { instance, propertyMap.properties(*instance, attributeName) }); >+ result.append(SVGElementAnimatedProperties { instance, instance->lookupOrCreateAnimatedProperties(attributeName) }); > > #if !ASSERT_DISABLED > for (auto& animatedProperties : result) { >diff --git a/Source/WebCore/svg/SVGAnimationElement.cpp b/Source/WebCore/svg/SVGAnimationElement.cpp >index 42627ac4037..fb6ea5f7cc3 100644 >--- a/Source/WebCore/svg/SVGAnimationElement.cpp >+++ b/Source/WebCore/svg/SVGAnimationElement.cpp >@@ -49,8 +49,8 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGAnimationElement); > > SVGAnimationElement::SVGAnimationElement(const QualifiedName& tagName, Document& document) > : SVGSMILElement(tagName, document) >- , SVGTests(*this) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGTests(this) > { > } > >diff --git a/Source/WebCore/svg/SVGAnimationElement.h b/Source/WebCore/svg/SVGAnimationElement.h >index 6c57da81869..bfe230c5df6 100644 >--- a/Source/WebCore/svg/SVGAnimationElement.h >+++ b/Source/WebCore/svg/SVGAnimationElement.h >@@ -52,7 +52,7 @@ enum AnimatedPropertyValueType { RegularPropertyValue, CurrentColorValue, Inheri > > enum class CalcMode { Discrete, Linear, Paced, Spline }; > >-class SVGAnimationElement : public SVGSMILElement, public SVGTests, public SVGExternalResourcesRequired { >+class SVGAnimationElement : public SVGSMILElement, public SVGExternalResourcesRequired, public SVGTests { > WTF_MAKE_ISO_ALLOCATED(SVGAnimationElement); > public: > float getStartTime() const; >@@ -149,7 +149,7 @@ public: > protected: > SVGAnimationElement(const QualifiedName&, Document&); > >- using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGAnimationElement, SVGElement, SVGTests, SVGExternalResourcesRequired>; >+ using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGAnimationElement, SVGElement, SVGExternalResourcesRequired, SVGTests>; > static AttributeOwnerProxy::AttributeRegistry& attributeRegistry() { return AttributeOwnerProxy::attributeRegistry(); } > const SVGAttributeOwnerProxy& attributeOwnerProxy() const override { return m_attributeOwnerProxy; } > >diff --git a/Source/WebCore/svg/SVGCircleElement.cpp b/Source/WebCore/svg/SVGCircleElement.cpp >index 52806c1f5e3..ef3daa6a88f 100644 >--- a/Source/WebCore/svg/SVGCircleElement.cpp >+++ b/Source/WebCore/svg/SVGCircleElement.cpp >@@ -32,7 +32,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGCircleElement); > > inline SVGCircleElement::SVGCircleElement(const QualifiedName& tagName, Document& document) > : SVGGeometryElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > ASSERT(hasTagName(SVGNames::circleTag)); > registerAttributes(); >diff --git a/Source/WebCore/svg/SVGClipPathElement.cpp b/Source/WebCore/svg/SVGClipPathElement.cpp >index 5bfd575f1fb..bdd35d7a808 100644 >--- a/Source/WebCore/svg/SVGClipPathElement.cpp >+++ b/Source/WebCore/svg/SVGClipPathElement.cpp >@@ -36,7 +36,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGClipPathElement); > > inline SVGClipPathElement::SVGClipPathElement(const QualifiedName& tagName, Document& document) > : SVGGraphicsElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > ASSERT(hasTagName(SVGNames::clipPathTag)); > registerAttributes(); >diff --git a/Source/WebCore/svg/SVGClipPathElement.h b/Source/WebCore/svg/SVGClipPathElement.h >index 704a436f599..c8766234def 100644 >--- a/Source/WebCore/svg/SVGClipPathElement.h >+++ b/Source/WebCore/svg/SVGClipPathElement.h >@@ -36,7 +36,7 @@ class SVGClipPathElement final : public SVGGraphicsElement, public SVGExternalRe > public: > static Ref<SVGClipPathElement> create(const QualifiedName&, Document&); > >- const SVGUnitTypes::SVGUnitType& clipPathUnits() const { return m_clipPathUnits.currentValue(); } >+ SVGUnitTypes::SVGUnitType clipPathUnits() const { return m_clipPathUnits.currentValue(); } > RefPtr<SVGAnimatedEnumeration> clipPathUnitsAnimated() { return m_clipPathUnits.animatedProperty(); } > > private: >diff --git a/Source/WebCore/svg/SVGComponentTransferFunctionElement.h b/Source/WebCore/svg/SVGComponentTransferFunctionElement.h >index 8a177ddfe7c..2354f00caa3 100644 >--- a/Source/WebCore/svg/SVGComponentTransferFunctionElement.h >+++ b/Source/WebCore/svg/SVGComponentTransferFunctionElement.h >@@ -78,10 +78,10 @@ public: > ComponentTransferType type() const { return m_type.currentValue(); } > const SVGNumberListValues& tableValues() const { return m_tableValues.currentValue(); } > float slope() const { return m_slope.currentValue(); } >- float auto& intercept() const { return m_intercept.currentValue(); } >- float auto& amplitude() const { return m_amplitude.currentValue(); } >- float auto& exponent() const { return m_exponent.currentValue(); } >- float auto& offset() const { return m_offset.currentValue(); } >+ float intercept() const { return m_intercept.currentValue(); } >+ float amplitude() const { return m_amplitude.currentValue(); } >+ float exponent() const { return m_exponent.currentValue(); } >+ float offset() const { return m_offset.currentValue(); } > > RefPtr<SVGAnimatedEnumeration> typeAnimated() { return m_type.animatedProperty(); } > RefPtr<SVGAnimatedNumberList> tableValuesAnimated() { return m_tableValues.animatedProperty(); } >diff --git a/Source/WebCore/svg/SVGCursorElement.cpp b/Source/WebCore/svg/SVGCursorElement.cpp >index 38e54e1d3f2..8dd70f2bee8 100644 >--- a/Source/WebCore/svg/SVGCursorElement.cpp >+++ b/Source/WebCore/svg/SVGCursorElement.cpp >@@ -36,9 +36,9 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGCursorElement); > > inline SVGCursorElement::SVGCursorElement(const QualifiedName& tagName, Document& document) > : SVGElement(tagName, document) >- , SVGTests(*this) >- , SVGExternalResourcesRequired(*this) >- , SVGURIReference(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGTests(this) >+ , SVGURIReference(this) > { > ASSERT(hasTagName(SVGNames::cursorTag)); > registerAttributes(); >diff --git a/Source/WebCore/svg/SVGCursorElement.h b/Source/WebCore/svg/SVGCursorElement.h >index b7c5433c209..4586a20a0a4 100644 >--- a/Source/WebCore/svg/SVGCursorElement.h >+++ b/Source/WebCore/svg/SVGCursorElement.h >@@ -33,7 +33,7 @@ namespace WebCore { > > class CSSCursorImageValue; > >-class SVGCursorElement final : public SVGElement, public SVGTests, public SVGExternalResourcesRequired, public SVGURIReference { >+class SVGCursorElement final : public SVGElement, public SVGExternalResourcesRequired, public SVGTests, public SVGURIReference { > WTF_MAKE_ISO_ALLOCATED(SVGCursorElement); > public: > static Ref<SVGCursorElement> create(const QualifiedName&, Document&); >@@ -52,7 +52,7 @@ public: > private: > SVGCursorElement(const QualifiedName&, Document&); > >- using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGCursorElement, SVGElement, SVGTests, SVGExternalResourcesRequired, SVGURIReference>; >+ using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGCursorElement, SVGElement, SVGExternalResourcesRequired, SVGTests, SVGURIReference>; > static AttributeOwnerProxy::AttributeRegistry& attributeRegistry() { return AttributeOwnerProxy::attributeRegistry(); } > static bool isKnownAttribute(const QualifiedName& attributeName) { return AttributeOwnerProxy::isKnownAttribute(attributeName); } > static void registerAttributes(); >diff --git a/Source/WebCore/svg/SVGDefsElement.cpp b/Source/WebCore/svg/SVGDefsElement.cpp >index 62ede103fbe..acbe55e183b 100644 >--- a/Source/WebCore/svg/SVGDefsElement.cpp >+++ b/Source/WebCore/svg/SVGDefsElement.cpp >@@ -32,7 +32,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGDefsElement); > > inline SVGDefsElement::SVGDefsElement(const QualifiedName& tagName, Document& document) > : SVGGraphicsElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > ASSERT(hasTagName(SVGNames::defsTag)); > } >diff --git a/Source/WebCore/svg/SVGElement.cpp b/Source/WebCore/svg/SVGElement.cpp >index b474f5d99f1..9357abb1e05 100644 >--- a/Source/WebCore/svg/SVGElement.cpp >+++ b/Source/WebCore/svg/SVGElement.cpp >@@ -710,7 +710,7 @@ void SVGElement::synchronizeAnimatedSVGAttribute(const QualifiedName& name) cons > if (name == anyQName()) > synchronizeAllAnimatedSVGAttribute(nonConstThis); > else >- nonConstThis->synchronizeAttribute(*nonConstThis, name); >+ nonConstThis->synchronizeAttribute(name); > } > > std::optional<ElementStyle> SVGElement::resolveCustomStyle(const RenderStyle& parentStyle, const RenderStyle*) >diff --git a/Source/WebCore/svg/SVGElement.h b/Source/WebCore/svg/SVGElement.h >index 58b01f2c0ff..08b544fc4e9 100644 >--- a/Source/WebCore/svg/SVGElement.h >+++ b/Source/WebCore/svg/SVGElement.h >@@ -128,6 +128,7 @@ public: > void callClearTarget() { clearTarget(); } > > class InstanceUpdateBlocker; >+ class InstanceInvalidationGuard; > > // The definition of the owner proxy has to match the class inheritance but we are interested in the SVG objects only. > using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGElement, SVGLangSpace>; >@@ -181,8 +182,6 @@ protected: > > void willRecalcStyle(Style::Change) override; > >- class InstanceInvalidationGuard; >- > private: > const RenderStyle* computedStyle(PseudoId = PseudoId::None) final; > >diff --git a/Source/WebCore/svg/SVGEllipseElement.cpp b/Source/WebCore/svg/SVGEllipseElement.cpp >index 294429da9c1..0a54b1875d8 100644 >--- a/Source/WebCore/svg/SVGEllipseElement.cpp >+++ b/Source/WebCore/svg/SVGEllipseElement.cpp >@@ -32,7 +32,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGEllipseElement); > > inline SVGEllipseElement::SVGEllipseElement(const QualifiedName& tagName, Document& document) > : SVGGeometryElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > ASSERT(hasTagName(SVGNames::ellipseTag)); > registerAttributes(); >diff --git a/Source/WebCore/svg/SVGExternalResourcesRequired.cpp b/Source/WebCore/svg/SVGExternalResourcesRequired.cpp >index 148d4559318..bcea635715b 100644 >--- a/Source/WebCore/svg/SVGExternalResourcesRequired.cpp >+++ b/Source/WebCore/svg/SVGExternalResourcesRequired.cpp >@@ -27,9 +27,9 @@ > > namespace WebCore { > >-SVGExternalResourcesRequired::SVGExternalResourcesRequired(SVGElement& contextElement) >- : m_contextElement(contextElement) >- , m_attributeOwnerProxy(*this, contextElement) >+SVGExternalResourcesRequired::SVGExternalResourcesRequired(SVGElement* contextElement) >+ : m_contextElement(*contextElement) >+ , m_attributeOwnerProxy(*this, *contextElement) > { > registerAttributes(); > } >@@ -62,7 +62,7 @@ void SVGExternalResourcesRequired::svgAttributeChanged(const QualifiedName& attr > setHaveFiredLoadEvent(true); > > ASSERT(m_contextElement.haveLoadedRequiredResources()); >- m_contextElement.sendSVGLoadEventIfPossible() >+ m_contextElement.sendSVGLoadEventIfPossible(); > } > > auto* renderer = m_contextElement.renderer(); >@@ -79,8 +79,6 @@ void SVGExternalResourcesRequired::addSupportedAttributes(HashSet<QualifiedName> > > void SVGExternalResourcesRequired::dispatchLoadEvent() > { >- bool externalResourcesRequired = externalResourcesRequiredBaseValue(); >- > if (isParserInserted()) > ASSERT(externalResourcesRequired() != haveFiredLoadEvent()); > else if (haveFiredLoadEvent()) >diff --git a/Source/WebCore/svg/SVGExternalResourcesRequired.h b/Source/WebCore/svg/SVGExternalResourcesRequired.h >index f7d4f190fa2..d24d79a4b28 100644 >--- a/Source/WebCore/svg/SVGExternalResourcesRequired.h >+++ b/Source/WebCore/svg/SVGExternalResourcesRequired.h >@@ -35,6 +35,7 @@ class SVGElement; > // states that externalResourcesRequired cannot be animated, the animVal will always be the same as the baseVal. > // FIXME: When implementing animVal support, make sure that animVal==baseVal for externalResourcesRequired > class SVGExternalResourcesRequired { >+ WTF_MAKE_NONCOPYABLE(SVGExternalResourcesRequired); > public: > virtual ~SVGExternalResourcesRequired() = default; > >@@ -52,7 +53,7 @@ public: > void setExternalResourcesRequired(bool externalResourcesRequired) { m_externalResourcesRequired.setValue(externalResourcesRequired); } > > protected: >- SVGExternalResourcesRequired(SVGElement& contextElement); >+ SVGExternalResourcesRequired(SVGElement* contextElement); > > static bool isKnownAttribute(const QualifiedName& attributeName) { return AttributeOwnerProxy::isKnownAttribute(attributeName); } > >diff --git a/Source/WebCore/svg/SVGFEComponentTransferElement.cpp b/Source/WebCore/svg/SVGFEComponentTransferElement.cpp >index d011275c155..57faf3b4630 100644 >--- a/Source/WebCore/svg/SVGFEComponentTransferElement.cpp >+++ b/Source/WebCore/svg/SVGFEComponentTransferElement.cpp >@@ -36,9 +36,6 @@ namespace WebCore { > > WTF_MAKE_ISO_ALLOCATED_IMPL(SVGFEComponentTransferElement); > >-// Animated property definitions >-DEFINE_ANIMATED_STRING(SVGFEComponentTransferElement, SVGNames::inAttr, In1, in1) >- > inline SVGFEComponentTransferElement::SVGFEComponentTransferElement(const QualifiedName& tagName, Document& document) > : SVGFilterPrimitiveStandardAttributes(tagName, document) > { >diff --git a/Source/WebCore/svg/SVGFECompositeElement.cpp b/Source/WebCore/svg/SVGFECompositeElement.cpp >index c556246e61b..a10e3a721cf 100644 >--- a/Source/WebCore/svg/SVGFECompositeElement.cpp >+++ b/Source/WebCore/svg/SVGFECompositeElement.cpp >@@ -33,7 +33,6 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGFECompositeElement); > > inline SVGFECompositeElement::SVGFECompositeElement(const QualifiedName& tagName, Document& document) > : SVGFilterPrimitiveStandardAttributes(tagName, document) >- , m_svgOperator(FECOMPOSITE_OPERATOR_OVER) > { > ASSERT(hasTagName(SVGNames::feCompositeTag)); > registerAttributes(); >diff --git a/Source/WebCore/svg/SVGFEConvolveMatrixElement.cpp b/Source/WebCore/svg/SVGFEConvolveMatrixElement.cpp >index d0b3b6ed8dc..676e1b254fe 100644 >--- a/Source/WebCore/svg/SVGFEConvolveMatrixElement.cpp >+++ b/Source/WebCore/svg/SVGFEConvolveMatrixElement.cpp >@@ -122,7 +122,7 @@ void SVGFEConvolveMatrixElement::parseAttribute(const QualifiedName& name, const > SVGNumberListValues newList; > newList.parse(value); > m_kernelMatrix.detachAnimatedListWrappers(newList.size()); >- m_kernelMatrix.setValue(WYFMove(newList)); >+ m_kernelMatrix.setValue(WTFMove(newList)); > return; > } > >diff --git a/Source/WebCore/svg/SVGFEImageElement.cpp b/Source/WebCore/svg/SVGFEImageElement.cpp >index bc36886d0ff..3a41928a28e 100644 >--- a/Source/WebCore/svg/SVGFEImageElement.cpp >+++ b/Source/WebCore/svg/SVGFEImageElement.cpp >@@ -41,8 +41,8 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGFEImageElement); > > inline SVGFEImageElement::SVGFEImageElement(const QualifiedName& tagName, Document& document) > : SVGFilterPrimitiveStandardAttributes(tagName, document) >- , SVGURIReference(*this) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGURIReference(this) > { > ASSERT(hasTagName(SVGNames::feImageTag)); > registerAttributes(); >diff --git a/Source/WebCore/svg/SVGFEImageElement.h b/Source/WebCore/svg/SVGFEImageElement.h >index b31ade4e8e7..d1512d8220b 100644 >--- a/Source/WebCore/svg/SVGFEImageElement.h >+++ b/Source/WebCore/svg/SVGFEImageElement.h >@@ -32,7 +32,7 @@ > > namespace WebCore { > >-class SVGFEImageElement final : public SVGFilterPrimitiveStandardAttributes, public SVGURIReference, public SVGExternalResourcesRequired, public CachedImageClient { >+class SVGFEImageElement final : public SVGFilterPrimitiveStandardAttributes, public SVGExternalResourcesRequired, public SVGURIReference, public CachedImageClient { > WTF_MAKE_ISO_ALLOCATED(SVGFEImageElement); > public: > static Ref<SVGFEImageElement> create(const QualifiedName&, Document&); >@@ -41,13 +41,13 @@ public: > > bool hasSingleSecurityOrigin() const; > >- const SVGPreserveAspectRatio& preserveAspectRatio() const { return m_preserveAspectRatio.currentValue(); } >- RefPtr<SVGPreserveAspectRatio> preserveAspectRatioAnimated() { return m_preserveAspectRatio.animatedProperty(); } >+ const SVGPreserveAspectRatioValue& preserveAspectRatio() const { return m_preserveAspectRatio.currentValue(); } >+ RefPtr<SVGAnimatedPreserveAspectRatio> preserveAspectRatioAnimated() { return m_preserveAspectRatio.animatedProperty(); } > > private: > SVGFEImageElement(const QualifiedName&, Document&); > >- using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGFEImageElement, SVGFilterPrimitiveStandardAttributes, SVGURIReference, SVGExternalResourcesRequired>; >+ using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGFEImageElement, SVGFilterPrimitiveStandardAttributes, SVGExternalResourcesRequired, SVGURIReference>; > static AttributeOwnerProxy::AttributeRegistry& attributeRegistry() { return AttributeOwnerProxy::attributeRegistry(); } > static bool isKnownAttribute(const QualifiedName& attributeName) { return AttributeOwnerProxy::isKnownAttribute(attributeName); } > static void registerAttributes(); >diff --git a/Source/WebCore/svg/SVGFilterElement.cpp b/Source/WebCore/svg/SVGFilterElement.cpp >index 3f43e8713e6..f5a208a6a20 100644 >--- a/Source/WebCore/svg/SVGFilterElement.cpp >+++ b/Source/WebCore/svg/SVGFilterElement.cpp >@@ -41,8 +41,8 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGFilterElement); > > inline SVGFilterElement::SVGFilterElement(const QualifiedName& tagName, Document& document) > : SVGElement(tagName, document) >- , SVGURIReference(*this) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGURIReference(this) > { > // Spec: If the x/y attribute is not specified, the effect is as if a value of "-10%" were specified. > // Spec: If the width/height attribute is not specified, the effect is as if a value of "120%" were specified. >@@ -103,7 +103,7 @@ void SVGFilterElement::parseAttribute(const QualifiedName& name, const AtomicStr > } else if (name == SVGNames::primitiveUnitsAttr) { > SVGUnitTypes::SVGUnitType propertyValue = SVGPropertyTraits<SVGUnitTypes::SVGUnitType>::fromString(value); > if (propertyValue > 0) >- m_primitiveUnits.setValue((propertyValue); >+ m_primitiveUnits.setValue(propertyValue); > } else if (name == SVGNames::xAttr) > m_x.setValue(SVGLengthValue::construct(LengthModeWidth, value, parseError)); > else if (name == SVGNames::yAttr) >diff --git a/Source/WebCore/svg/SVGFilterElement.h b/Source/WebCore/svg/SVGFilterElement.h >index 48d1f4fd96d..19cb6f00950 100644 >--- a/Source/WebCore/svg/SVGFilterElement.h >+++ b/Source/WebCore/svg/SVGFilterElement.h >@@ -33,7 +33,7 @@ > > namespace WebCore { > >-class SVGFilterElement final : public SVGElement, public SVGURIReference, public SVGExternalResourcesRequired { >+class SVGFilterElement final : public SVGElement, public SVGExternalResourcesRequired, public SVGURIReference { > WTF_MAKE_ISO_ALLOCATED(SVGFilterElement); > public: > static Ref<SVGFilterElement> create(const QualifiedName&, Document&); >@@ -61,7 +61,7 @@ public: > private: > SVGFilterElement(const QualifiedName&, Document&); > >- using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGFilterElement, SVGElement, SVGURIReference, SVGExternalResourcesRequired>; >+ using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGFilterElement, SVGElement, SVGExternalResourcesRequired, SVGURIReference>; > static AttributeOwnerProxy::AttributeRegistry& attributeRegistry() { return AttributeOwnerProxy::attributeRegistry(); } > static bool isKnownAttribute(const QualifiedName& attributeName) { return AttributeOwnerProxy::isKnownAttribute(attributeName); } > static bool isAnimatedLengthAttribute(const QualifiedName& attributeName) { return AttributeOwnerProxy::isAnimatedLengthAttribute(attributeName); } >diff --git a/Source/WebCore/svg/SVGFilterPrimitiveStandardAttributes.cpp b/Source/WebCore/svg/SVGFilterPrimitiveStandardAttributes.cpp >index d11343d6197..88806fb972f 100644 >--- a/Source/WebCore/svg/SVGFilterPrimitiveStandardAttributes.cpp >+++ b/Source/WebCore/svg/SVGFilterPrimitiveStandardAttributes.cpp >@@ -39,18 +39,6 @@ SVGFilterPrimitiveStandardAttributes::SVGFilterPrimitiveStandardAttributes(const > registerAttributes(); > } > >-bool SVGFilterPrimitiveStandardAttributes::isSupportedAttribute(const QualifiedName& attrName) >-{ >- static const auto supportedAttributes = makeNeverDestroyed(HashSet<QualifiedName> { >- SVGNames::xAttr.get(), >- SVGNames::yAttr.get(), >- SVGNames::widthAttr.get(), >- SVGNames::heightAttr.get(), >- SVGNames::resultAttr.get(), >- }); >- return supportedAttributes.get().contains<SVGAttributeHashTranslator>(attrName); >-} >- > void SVGFilterPrimitiveStandardAttributes::registerAttributes() > { > auto& registry = attributeRegistry(); >diff --git a/Source/WebCore/svg/SVGFitToViewBox.cpp b/Source/WebCore/svg/SVGFitToViewBox.cpp >index e49242a26a9..80f73a211ee 100644 >--- a/Source/WebCore/svg/SVGFitToViewBox.cpp >+++ b/Source/WebCore/svg/SVGFitToViewBox.cpp >@@ -26,6 +26,7 @@ > #include "Document.h" > #include "FloatRect.h" > #include "SVGDocumentExtensions.h" >+#include "SVGElement.h" > #include "SVGNames.h" > #include "SVGParserUtilities.h" > #include "SVGPreserveAspectRatioValue.h" >@@ -33,9 +34,9 @@ > > namespace WebCore { > >-SVGFitToViewBox::SVGFitToViewBox(SVGElement& contextElement, AnimatedPropertyState animatedState) >- : m_contextElement(contextElement) >- , m_attributeOwnerProxy(*this, contextElement, animatedState) >+SVGFitToViewBox::SVGFitToViewBox(SVGElement* contextElement, AnimatedPropertyState animatedState) >+ : m_document(contextElement->document()) >+ , m_attributeOwnerProxy(*this, *contextElement, animatedState) > { > registerAttributes(); > } >@@ -108,29 +109,27 @@ bool SVGFitToViewBox::parseViewBox(const UChar*& c, const UChar* end, FloatRect& > bool valid = parseNumber(c, end, x) && parseNumber(c, end, y) && parseNumber(c, end, width) && parseNumber(c, end, height, false); > > if (validate) { >- Document& document = m_contextElement.document(); >- > if (!valid) { >- document.accessSVGExtensions().reportWarning("Problem parsing viewBox=\"" + str + "\""); >+ m_document.accessSVGExtensions().reportWarning("Problem parsing viewBox=\"" + str + "\""); > return false; > } > > // Check that width is positive. > if (width < 0.0) { >- document.accessSVGExtensions().reportError("A negative value for ViewBox width is not allowed"); >+ m_document.accessSVGExtensions().reportError("A negative value for ViewBox width is not allowed"); > return false; > } > > // Check that height is positive. > if (height < 0.0) { >- document.accessSVGExtensions().reportError("A negative value for ViewBox height is not allowed"); >+ m_document.accessSVGExtensions().reportError("A negative value for ViewBox height is not allowed"); > return false; > } > > // Nothing should come after the last, fourth number. > skipOptionalSVGSpaces(c, end); > if (c < end) { >- document.accessSVGExtensions().reportWarning("Problem parsing viewBox=\"" + str + "\""); >+ m_document.accessSVGExtensions().reportWarning("Problem parsing viewBox=\"" + str + "\""); > return false; > } > } >@@ -139,14 +138,6 @@ bool SVGFitToViewBox::parseViewBox(const UChar*& c, const UChar* end, FloatRect& > return true; > } > >-void SVGFitToViewBox::svgAttributeChanged(const QualifiedName& attrName) >-{ >- if (attrName == SVGNames::viewBoxAttr) { >- InstanceInvalidationGuard guard(m_contextElement); >- updateRelativeLengthsInformation(); >- } >-} >- > AffineTransform SVGFitToViewBox::viewBoxToViewTransform(const FloatRect& viewBoxRect, const SVGPreserveAspectRatioValue& preserveAspectRatio, float viewWidth, float viewHeight) > { > if (!viewBoxRect.width() || !viewBoxRect.height() || !viewWidth || !viewHeight) >diff --git a/Source/WebCore/svg/SVGFitToViewBox.h b/Source/WebCore/svg/SVGFitToViewBox.h >index 70ab59ea556..e4517762bc7 100644 >--- a/Source/WebCore/svg/SVGFitToViewBox.h >+++ b/Source/WebCore/svg/SVGFitToViewBox.h >@@ -34,6 +34,7 @@ class AffineTransform; > class Document; > > class SVGFitToViewBox { >+ WTF_MAKE_NONCOPYABLE(SVGFitToViewBox); > public: > static AffineTransform viewBoxToViewTransform(const FloatRect& viewBoxRect, const SVGPreserveAspectRatioValue&, float viewWidth, float viewHeight); > >@@ -59,7 +60,7 @@ public: > bool hasEmptyViewBox() const { return m_isViewBoxValid && viewBox().isEmpty(); } > > protected: >- SVGFitToViewBox(SVGElement& contextElement, AnimatedPropertyState = PropertyIsReadWrite); >+ SVGFitToViewBox(SVGElement* contextElement, AnimatedPropertyState = PropertyIsReadWrite); > > static bool isKnownAttribute(const QualifiedName& attributeName) { return AttributeOwnerProxy::isKnownAttribute(attributeName); } > >@@ -67,12 +68,11 @@ protected: > bool parseAttribute(const QualifiedName&, const AtomicString&); > bool parseViewBox(const AtomicString& value, FloatRect& viewBox); > bool parseViewBox(const UChar*& start, const UChar* end, FloatRect& viewBox, bool validate = true); >- void svgAttributeChanged(const QualifiedName&); > > private: > static void registerAttributes(); > >- SVGElement& m_contextElement; >+ Document& m_document; > AttributeOwnerProxy m_attributeOwnerProxy; > SVGAnimatedRectAttribute m_viewBox { m_attributeOwnerProxy }; > SVGAnimatedPreserveAspectRatioAttribute m_preserveAspectRatio { m_attributeOwnerProxy }; >diff --git a/Source/WebCore/svg/SVGFontElement.cpp b/Source/WebCore/svg/SVGFontElement.cpp >index 4f231fa4906..6855d834426 100644 >--- a/Source/WebCore/svg/SVGFontElement.cpp >+++ b/Source/WebCore/svg/SVGFontElement.cpp >@@ -42,7 +42,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGFontElement); > > inline SVGFontElement::SVGFontElement(const QualifiedName& tagName, Document& document) > : SVGElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > ASSERT(hasTagName(SVGNames::fontTag)); > } >diff --git a/Source/WebCore/svg/SVGForeignObjectElement.cpp b/Source/WebCore/svg/SVGForeignObjectElement.cpp >index fdc16086848..0492077230e 100644 >--- a/Source/WebCore/svg/SVGForeignObjectElement.cpp >+++ b/Source/WebCore/svg/SVGForeignObjectElement.cpp >@@ -38,7 +38,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGForeignObjectElement); > > inline SVGForeignObjectElement::SVGForeignObjectElement(const QualifiedName& tagName, Document& document) > : SVGGraphicsElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > ASSERT(hasTagName(SVGNames::foreignObjectTag)); > registerAttributes(); >diff --git a/Source/WebCore/svg/SVGGElement.cpp b/Source/WebCore/svg/SVGGElement.cpp >index f1e4ad2fbe8..7df6ea6dcf2 100644 >--- a/Source/WebCore/svg/SVGGElement.cpp >+++ b/Source/WebCore/svg/SVGGElement.cpp >@@ -35,7 +35,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGGElement); > > SVGGElement::SVGGElement(const QualifiedName& tagName, Document& document) > : SVGGraphicsElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > ASSERT(hasTagName(SVGNames::gTag)); > } >diff --git a/Source/WebCore/svg/SVGGeometryElement.cpp b/Source/WebCore/svg/SVGGeometryElement.cpp >index 5127700d55c..72dd3f13598 100644 >--- a/Source/WebCore/svg/SVGGeometryElement.cpp >+++ b/Source/WebCore/svg/SVGGeometryElement.cpp >@@ -99,7 +99,7 @@ void SVGGeometryElement::parseAttribute(const QualifiedName& name, const AtomicS > { > if (name == SVGNames::pathLengthAttr) { > m_pathLength.setValue(value.toFloat()); >- if ((m_pathLength.value() < 0) >+ if (m_pathLength.value() < 0) > document().accessSVGExtensions().reportError("A negative value for path attribute <pathLength> is not allowed"); > return; > } >diff --git a/Source/WebCore/svg/SVGGlyphRefElement.cpp b/Source/WebCore/svg/SVGGlyphRefElement.cpp >index 6660b0c8430..24cdd40e829 100644 >--- a/Source/WebCore/svg/SVGGlyphRefElement.cpp >+++ b/Source/WebCore/svg/SVGGlyphRefElement.cpp >@@ -36,7 +36,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGGlyphRefElement); > > inline SVGGlyphRefElement::SVGGlyphRefElement(const QualifiedName& tagName, Document& document) > : SVGElement(tagName, document) >- , SVGURIReference(*this) >+ , SVGURIReference(this) > { > ASSERT(hasTagName(SVGNames::glyphRefTag)); > } >diff --git a/Source/WebCore/svg/SVGGlyphRefElement.h b/Source/WebCore/svg/SVGGlyphRefElement.h >index c2f53bf5afb..8810d5b0926 100644 >--- a/Source/WebCore/svg/SVGGlyphRefElement.h >+++ b/Source/WebCore/svg/SVGGlyphRefElement.h >@@ -56,6 +56,7 @@ private: > float m_y { 0 }; > float m_dx { 0 }; > float m_dy { 0 }; >+ AttributeOwnerProxy m_attributeOwnerProxy { *this }; > }; > > } >diff --git a/Source/WebCore/svg/SVGGradientElement.cpp b/Source/WebCore/svg/SVGGradientElement.cpp >index 66acfb42aea..122fcc24ae9 100644 >--- a/Source/WebCore/svg/SVGGradientElement.cpp >+++ b/Source/WebCore/svg/SVGGradientElement.cpp >@@ -42,8 +42,8 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGGradientElement); > > SVGGradientElement::SVGGradientElement(const QualifiedName& tagName, Document& document) > : SVGElement(tagName, document) >- , SVGURIReference(*this) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGURIReference(this) > { > registerAttributes(); > } >diff --git a/Source/WebCore/svg/SVGGradientElement.h b/Source/WebCore/svg/SVGGradientElement.h >index 46150270c6d..a5b73d54b00 100644 >--- a/Source/WebCore/svg/SVGGradientElement.h >+++ b/Source/WebCore/svg/SVGGradientElement.h >@@ -73,7 +73,7 @@ struct SVGPropertyTraits<SVGSpreadMethodType> { > } > }; > >-class SVGGradientElement : public SVGElement, public SVGURIReference, public SVGExternalResourcesRequired { >+class SVGGradientElement : public SVGElement, public SVGExternalResourcesRequired, public SVGURIReference { > WTF_MAKE_ISO_ALLOCATED(SVGGradientElement); > public: > enum { >@@ -85,7 +85,7 @@ public: > > Vector<Gradient::ColorStop> buildStops(); > >- using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGGradientElement, SVGElement, SVGURIReference, SVGExternalResourcesRequired>; >+ using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGGradientElement, SVGElement, SVGExternalResourcesRequired, SVGURIReference>; > static AttributeOwnerProxy::AttributeRegistry& attributeRegistry() { return AttributeOwnerProxy::attributeRegistry(); } > > SVGSpreadMethodType spreadMethod() const { return m_spreadMethod.currentValue(); } >diff --git a/Source/WebCore/svg/SVGGraphicsElement.cpp b/Source/WebCore/svg/SVGGraphicsElement.cpp >index b621475a6fa..9d79674a206 100644 >--- a/Source/WebCore/svg/SVGGraphicsElement.cpp >+++ b/Source/WebCore/svg/SVGGraphicsElement.cpp >@@ -159,7 +159,7 @@ void SVGGraphicsElement::svgAttributeChanged(const QualifiedName& attrName) > } > > SVGElement::svgAttributeChanged(attrName); >- SVGTests::handleAttributeChange(attrName); >+ SVGTests::svgAttributeChanged(attrName); > } > > SVGElement* SVGGraphicsElement::nearestViewportElement() const >diff --git a/Source/WebCore/svg/SVGImageElement.cpp b/Source/WebCore/svg/SVGImageElement.cpp >index 580ae997bac..f93937736ed 100644 >--- a/Source/WebCore/svg/SVGImageElement.cpp >+++ b/Source/WebCore/svg/SVGImageElement.cpp >@@ -39,8 +39,8 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGImageElement); > > inline SVGImageElement::SVGImageElement(const QualifiedName& tagName, Document& document) > : SVGGraphicsElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >- , SVGURIReference(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGURIReference(this) > , m_imageLoader(*this) > { > registerAttributes(); >@@ -120,7 +120,8 @@ void SVGImageElement::svgAttributeChanged(const QualifiedName& attrName) > > if (attrName == SVGNames::preserveAspectRatioAttr) { > InstanceInvalidationGuard guard(*this); >- RenderSVGResource::markForLayoutAndParentResourceInvalidation(*renderer); >+ if (auto* renderer = this->renderer()) >+ RenderSVGResource::markForLayoutAndParentResourceInvalidation(*renderer); > return; > } > >diff --git a/Source/WebCore/svg/SVGImageLoader.cpp b/Source/WebCore/svg/SVGImageLoader.cpp >index 87e8cb7ea64..32768827c6a 100644 >--- a/Source/WebCore/svg/SVGImageLoader.cpp >+++ b/Source/WebCore/svg/SVGImageLoader.cpp >@@ -41,7 +41,7 @@ void SVGImageLoader::dispatchLoadEvent() > if (image()->errorOccurred()) > element().dispatchEvent(Event::create(eventNames().errorEvent, false, false)); > else { >- if (downcast<SVGImageElement>(element()).externalResourcesRequiredBaseValue()) >+ if (downcast<SVGImageElement>(element()).externalResourcesRequired()) > downcast<SVGImageElement>(ImageLoader::element()).sendSVGLoadEventIfPossible(true); > } > } >diff --git a/Source/WebCore/svg/SVGLineElement.cpp b/Source/WebCore/svg/SVGLineElement.cpp >index 626b4732f8a..da54067b405 100644 >--- a/Source/WebCore/svg/SVGLineElement.cpp >+++ b/Source/WebCore/svg/SVGLineElement.cpp >@@ -32,10 +32,10 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGLineElement); > > inline SVGLineElement::SVGLineElement(const QualifiedName& tagName, Document& document) > : SVGGeometryElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > ASSERT(hasTagName(SVGNames::lineTag)); >- egisterAttributes(); >+ registerAttributes(); > } > > Ref<SVGLineElement> SVGLineElement::create(const QualifiedName& tagName, Document& document) >diff --git a/Source/WebCore/svg/SVGMPathElement.cpp b/Source/WebCore/svg/SVGMPathElement.cpp >index c6f58bd8f3b..93c8d4357b0 100644 >--- a/Source/WebCore/svg/SVGMPathElement.cpp >+++ b/Source/WebCore/svg/SVGMPathElement.cpp >@@ -34,8 +34,8 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGMPathElement); > > inline SVGMPathElement::SVGMPathElement(const QualifiedName& tagName, Document& document) > : SVGElement(tagName, document) >- , SVGURIReference(*this) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGURIReference(this) > { > ASSERT(hasTagName(SVGNames::mpathTag)); > } >diff --git a/Source/WebCore/svg/SVGMPathElement.h b/Source/WebCore/svg/SVGMPathElement.h >index c486b801ca3..39c9ea04518 100644 >--- a/Source/WebCore/svg/SVGMPathElement.h >+++ b/Source/WebCore/svg/SVGMPathElement.h >@@ -31,7 +31,7 @@ namespace WebCore { > > class SVGPathElement; > >-class SVGMPathElement final : public SVGElement, public SVGURIReference, public SVGExternalResourcesRequired { >+class SVGMPathElement final : public SVGElement, public SVGExternalResourcesRequired, public SVGURIReference { > WTF_MAKE_ISO_ALLOCATED(SVGMPathElement); > public: > static Ref<SVGMPathElement> create(const QualifiedName&, Document&); >@@ -45,7 +45,7 @@ public: > private: > SVGMPathElement(const QualifiedName&, Document&); > >- using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGMPathElement, SVGElement, SVGURIReference, SVGExternalResourcesRequired>; >+ using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGMPathElement, SVGElement, SVGExternalResourcesRequired, SVGURIReference>; > > const SVGAttributeOwnerProxy& attributeOwnerProxy() const final { return m_attributeOwnerProxy; } > void parseAttribute(const QualifiedName&, const AtomicString&) final; >diff --git a/Source/WebCore/svg/SVGMarkerElement.cpp b/Source/WebCore/svg/SVGMarkerElement.cpp >index 836e957509c..6ab2b7ff22c 100644 >--- a/Source/WebCore/svg/SVGMarkerElement.cpp >+++ b/Source/WebCore/svg/SVGMarkerElement.cpp >@@ -35,8 +35,8 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGMarkerElement); > > inline SVGMarkerElement::SVGMarkerElement(const QualifiedName& tagName, Document& document) > : SVGElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >- , SVGFitToViewBox(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGFitToViewBox(this) > { > // Spec: If the markerWidth/markerHeight attribute is not specified, the effect is as if a value of "3" were specified. > ASSERT(hasTagName(SVGNames::markerTag)); >@@ -127,10 +127,15 @@ void SVGMarkerElement::svgAttributeChanged(const QualifiedName& attrName) > object->setNeedsLayout(); > return; > } >+ >+ if (SVGFitToViewBox::isKnownAttribute(attrName)) { >+ if (RenderObject* object = renderer()) >+ object->setNeedsLayout(); >+ return; >+ } > > SVGElement::svgAttributeChanged(attrName); >- SVGExternalResourcesRequired::svgAttributeChanged(attrName) >- SVGFitToViewBox::svgAttributeChanged(attrName); >+ SVGExternalResourcesRequired::svgAttributeChanged(attrName); > } > > void SVGMarkerElement::childrenChanged(const ChildChange& change) >diff --git a/Source/WebCore/svg/SVGMaskElement.cpp b/Source/WebCore/svg/SVGMaskElement.cpp >index db7ff9032a1..cd43fa630e2 100644 >--- a/Source/WebCore/svg/SVGMaskElement.cpp >+++ b/Source/WebCore/svg/SVGMaskElement.cpp >@@ -41,8 +41,8 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGMaskElement); > > inline SVGMaskElement::SVGMaskElement(const QualifiedName& tagName, Document& document) > : SVGElement(tagName, document) >- , SVGTests(*this) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGTests(this) > { > // Spec: If the x/y attribute is not specified, the effect is as if a value of "-10%" were specified. > // Spec: If the width/height attribute is not specified, the effect is as if a value of "120%" were specified. >diff --git a/Source/WebCore/svg/SVGMaskElement.h b/Source/WebCore/svg/SVGMaskElement.h >index 7af96e9c5d8..e04d49ee278 100644 >--- a/Source/WebCore/svg/SVGMaskElement.h >+++ b/Source/WebCore/svg/SVGMaskElement.h >@@ -31,7 +31,7 @@ > > namespace WebCore { > >-class SVGMaskElement final : public SVGElement, public SVGTests, public SVGExternalResourcesRequired { >+class SVGMaskElement final : public SVGElement, public SVGExternalResourcesRequired, public SVGTests { > WTF_MAKE_ISO_ALLOCATED(SVGMaskElement); > public: > static Ref<SVGMaskElement> create(const QualifiedName&, Document&); >@@ -48,14 +48,15 @@ public: > RefPtr<SVGAnimatedLength> widthAnimated() { return m_width.animatedProperty(); } > RefPtr<SVGAnimatedLength> heightAnimated() { return m_height.animatedProperty(); } > RefPtr<SVGAnimatedEnumeration> maskUnitsAnimated() { return m_maskUnits.animatedProperty(); } >- RefPtr<SVGAnimatedEnumeration maskContentUnitsAnimated() { return m_maskContentUnits.animatedProperty(); } >+ RefPtr<SVGAnimatedEnumeration> maskContentUnitsAnimated() { return m_maskContentUnits.animatedProperty(); } > > private: > SVGMaskElement(const QualifiedName&, Document&); > >- using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGMaskElement, SVGElement, SVGTests, SVGExternalResourcesRequired>; >+ using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGMaskElement, SVGElement, SVGExternalResourcesRequired, SVGTests>; > static AttributeOwnerProxy::AttributeRegistry& attributeRegistry() { return AttributeOwnerProxy::attributeRegistry(); } > static bool isKnownAttribute(const QualifiedName& attributeName) { return AttributeOwnerProxy::isKnownAttribute(attributeName); } >+ static bool isAnimatedLengthAttribute(const QualifiedName& attributeName) { return AttributeOwnerProxy::isAnimatedLengthAttribute(attributeName); } > static void registerAttributes(); > > const SVGAttributeOwnerProxy& attributeOwnerProxy() const final { return m_attributeOwnerProxy; } >diff --git a/Source/WebCore/svg/SVGPathElement.cpp b/Source/WebCore/svg/SVGPathElement.cpp >index 0c6d6bf89f4..5ded2300b4d 100644 >--- a/Source/WebCore/svg/SVGPathElement.cpp >+++ b/Source/WebCore/svg/SVGPathElement.cpp >@@ -58,7 +58,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGPathElement); > > inline SVGPathElement::SVGPathElement(const QualifiedName& tagName, Document& document) > : SVGGeometryElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > ASSERT(hasTagName(SVGNames::pathTag)); > registerAttributes(); >@@ -267,7 +267,7 @@ const SVGPathByteStream& SVGPathElement::pathByteStream() const > if (auto* animatedPathByteStream = static_cast<SVGAnimatedPathSegListPropertyTearOff*>(property.get())->animatedPathByteStream()) > return *animatedPathByteStream; > >- return *animatedPathByteStream; >+ return m_pathByteStream; > } > > Path SVGPathElement::pathForByteStream() const >diff --git a/Source/WebCore/svg/SVGPathSegListValues.h b/Source/WebCore/svg/SVGPathSegListValues.h >index 5c150f555d7..8681e31ff94 100644 >--- a/Source/WebCore/svg/SVGPathSegListValues.h >+++ b/Source/WebCore/svg/SVGPathSegListValues.h >@@ -77,6 +77,7 @@ private: > > template<> struct SVGPropertyTraits<SVGPathSegListValues> { > static SVGPathSegListValues initialValue() { return SVGPathSegListValues(PathSegUndefinedRole); } >+ static String toString(const SVGPathSegListValues& list) { return list.valueAsString(); } > > using ListItemType = RefPtr<SVGPathSeg>; > using ListItemTearOff = SVGPropertyTearOff<RefPtr<SVGPathSeg>>; >diff --git a/Source/WebCore/svg/SVGPathSegWithContext.h b/Source/WebCore/svg/SVGPathSegWithContext.h >index 573016ddbfa..0a7a0e825bb 100644 >--- a/Source/WebCore/svg/SVGPathSegWithContext.h >+++ b/Source/WebCore/svg/SVGPathSegWithContext.h >@@ -19,7 +19,7 @@ > > #pragma once > >-#include "SVGAnimatedPathSegListPropertyTearOff.h" >+#include "SVGPathElement.h" > > namespace WebCore { > >diff --git a/Source/WebCore/svg/SVGPatternElement.cpp b/Source/WebCore/svg/SVGPatternElement.cpp >index 81b0af66c90..e6aa27b0dcf 100644 >--- a/Source/WebCore/svg/SVGPatternElement.cpp >+++ b/Source/WebCore/svg/SVGPatternElement.cpp >@@ -48,10 +48,10 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGPatternElement); > > inline SVGPatternElement::SVGPatternElement(const QualifiedName& tagName, Document& document) > : SVGElement(tagName, document) >- , SVGURIReference(*this) >- , SVGTests(*this) >- , SVGExternalResourcesRequired(*this) >- , SVGFitToViewBox(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGFitToViewBox(this) >+ , SVGTests(this) >+ , SVGURIReference(this) > { > ASSERT(hasTagName(SVGNames::patternTag)); > registerAttributes(); >@@ -126,16 +126,14 @@ void SVGPatternElement::svgAttributeChanged(const QualifiedName& attrName) > return; > } > >- if (isKnownAttribute(attrName)) { >+ if (isKnownAttribute(attrName) || SVGFitToViewBox::isKnownAttribute(attrName)) { > if (RenderObject* object = renderer()) > object->setNeedsLayout(); > return; > } > > SVGElement::svgAttributeChanged(attrName); >- SVGURIReferencesvgAttributeChanged(attrName); >- SVGExternalResourcesRequiredsvgAttributeChanged(attrName); >- SVGFitToViewBoxsvgAttributeChanged(attrName); >+ SVGExternalResourcesRequired::svgAttributeChanged(attrName); > } > > void SVGPatternElement::childrenChanged(const ChildChange& change) >diff --git a/Source/WebCore/svg/SVGPatternElement.h b/Source/WebCore/svg/SVGPatternElement.h >index dcd65d80e80..8655301e674 100644 >--- a/Source/WebCore/svg/SVGPatternElement.h >+++ b/Source/WebCore/svg/SVGPatternElement.h >@@ -39,7 +39,7 @@ namespace WebCore { > > struct PatternAttributes; > >-class SVGPatternElement final : public SVGElement, public SVGURIReference, public SVGTests, public SVGExternalResourcesRequired, public SVGFitToViewBox { >+class SVGPatternElement final : public SVGElement, public SVGExternalResourcesRequired, public SVGFitToViewBox, public SVGTests, public SVGURIReference { > WTF_MAKE_ISO_ALLOCATED(SVGPatternElement); > public: > static Ref<SVGPatternElement> create(const QualifiedName&, Document&); >@@ -67,7 +67,7 @@ public: > private: > SVGPatternElement(const QualifiedName&, Document&); > >- using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGPatternElement, SVGElement, SVGURIReference, SVGTests, SVGExternalResourcesRequired, SVGFitToViewBox>; >+ using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGPatternElement, SVGElement, SVGExternalResourcesRequired, SVGFitToViewBox, SVGTests, SVGURIReference>; > static AttributeOwnerProxy::AttributeRegistry& attributeRegistry() { return AttributeOwnerProxy::attributeRegistry(); } > static bool isKnownAttribute(const QualifiedName& attributeName) { return AttributeOwnerProxy::isKnownAttribute(attributeName); } > static bool isAnimatedLengthAttribute(const QualifiedName& attributeName) { return AttributeOwnerProxy::isAnimatedLengthAttribute(attributeName); } >diff --git a/Source/WebCore/svg/SVGPolyElement.cpp b/Source/WebCore/svg/SVGPolyElement.cpp >index b1ef42f7beb..af6db56bcb0 100644 >--- a/Source/WebCore/svg/SVGPolyElement.cpp >+++ b/Source/WebCore/svg/SVGPolyElement.cpp >@@ -35,7 +35,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGPolyElement); > > SVGPolyElement::SVGPolyElement(const QualifiedName& tagName, Document& document) > : SVGGeometryElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > registerAttributes(); > } >diff --git a/Source/WebCore/svg/SVGPolyElement.h b/Source/WebCore/svg/SVGPolyElement.h >index d1b9170f562..fa0984c7559 100644 >--- a/Source/WebCore/svg/SVGPolyElement.h >+++ b/Source/WebCore/svg/SVGPolyElement.h >@@ -34,8 +34,6 @@ public: > Ref<SVGPointList> points(); > Ref<SVGPointList> animatedPoints(); > >- SVGPointListValues& pointList() const { return m_points.value; } >- > const SVGPointListValues& pointList() const { return m_points.value(); } > > size_t approximateMemoryCost() const override; >diff --git a/Source/WebCore/svg/SVGPreserveAspectRatioValue.cpp b/Source/WebCore/svg/SVGPreserveAspectRatioValue.cpp >index 54641af6d9e..d0bc716620f 100644 >--- a/Source/WebCore/svg/SVGPreserveAspectRatioValue.cpp >+++ b/Source/WebCore/svg/SVGPreserveAspectRatioValue.cpp >@@ -180,7 +180,7 @@ bool SVGPreserveAspectRatioValue::parseInternal(const UChar*& currParam, const U > return true; > } > >-void SVGPreserveAspectRatioValue::transformRect(FloatRect& destRect, FloatRect& srcRect) >+void SVGPreserveAspectRatioValue::transformRect(FloatRect& destRect, FloatRect& srcRect) const > { > if (m_align == SVG_PRESERVEASPECTRATIO_NONE) > return; >diff --git a/Source/WebCore/svg/SVGPreserveAspectRatioValue.h b/Source/WebCore/svg/SVGPreserveAspectRatioValue.h >index 5d956087b7e..6a7fca24a4d 100644 >--- a/Source/WebCore/svg/SVGPreserveAspectRatioValue.h >+++ b/Source/WebCore/svg/SVGPreserveAspectRatioValue.h >@@ -60,7 +60,7 @@ public: > ExceptionOr<void> setMeetOrSlice(unsigned short); > unsigned short meetOrSlice() const { return m_meetOrSlice; } > >- void transformRect(FloatRect& destRect, FloatRect& srcRect); >+ void transformRect(FloatRect& destRect, FloatRect& srcRect) const; > > AffineTransform getCTM(float logicalX, float logicalY, float logicalWidth, float logicalHeight, float physicalWidth, float physicalHeight) const; > >diff --git a/Source/WebCore/svg/SVGRectElement.cpp b/Source/WebCore/svg/SVGRectElement.cpp >index 014653fae67..cfdf196d035 100644 >--- a/Source/WebCore/svg/SVGRectElement.cpp >+++ b/Source/WebCore/svg/SVGRectElement.cpp >@@ -33,7 +33,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGRectElement); > > inline SVGRectElement::SVGRectElement(const QualifiedName& tagName, Document& document) > : SVGGeometryElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > ASSERT(hasTagName(SVGNames::rectTag)); > registerAttributes(); >diff --git a/Source/WebCore/svg/SVGSVGElement.cpp b/Source/WebCore/svg/SVGSVGElement.cpp >index e9f245dfab4..6c636a3839c 100644 >--- a/Source/WebCore/svg/SVGSVGElement.cpp >+++ b/Source/WebCore/svg/SVGSVGElement.cpp >@@ -54,9 +54,9 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGSVGElement); > > inline SVGSVGElement::SVGSVGElement(const QualifiedName& tagName, Document& document) > : SVGGraphicsElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >- , SVGFitToViewBox(*this) >- , SVGZoomAndPan(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGFitToViewBox(this) >+ , SVGZoomAndPan(this) > , m_timeContainer(SMILTimeContainer::create(*this)) > { > ASSERT(hasTagName(SVGNames::svgTag)); >@@ -281,11 +281,17 @@ void SVGSVGElement::svgAttributeChanged(const QualifiedName& attrName) > RenderSVGResource::markForLayoutAndParentResourceInvalidation(*renderer); > return; > } >+ >+ if (SVGFitToViewBox::isKnownAttribute(attrName)) { >+ if (auto* renderer = this->renderer()) { >+ renderer->setNeedsTransformUpdate(); >+ RenderSVGResource::markForLayoutAndParentResourceInvalidation(*renderer); >+ } >+ return; >+ } > > SVGGraphicsElement::svgAttributeChanged(attrName); > SVGExternalResourcesRequired::svgAttributeChanged(attrName); >- SVGFitToViewBox::svgAttributeChanged(attrName); >- SVGZoomAndPan::svgAttributeChanged(attrName); > } > > unsigned SVGSVGElement::suspendRedraw(unsigned) >@@ -718,9 +724,9 @@ void SVGSVGElement::inheritViewAttributes(const SVGViewElement& viewElement) > view.setViewBox(viewBox()); > > if (viewElement.hasAttribute(SVGNames::preserveAspectRatioAttr)) >- view.setPreserveAspectRatio(viewElement.preserveAspectRatioBaseValue()); >+ view.setPreserveAspectRatio(viewElement.preserveAspectRatio()); > else >- view.setPreserveAspectRatio(preserveAspectRatioBaseValue()); >+ view.setPreserveAspectRatio(preserveAspectRatio()); > > if (viewElement.hasAttribute(SVGNames::zoomAndPanAttr)) > view.setZoomAndPan(viewElement.zoomAndPan()); >diff --git a/Source/WebCore/svg/SVGScriptElement.cpp b/Source/WebCore/svg/SVGScriptElement.cpp >index c951247bd7f..9c333ed1906 100644 >--- a/Source/WebCore/svg/SVGScriptElement.cpp >+++ b/Source/WebCore/svg/SVGScriptElement.cpp >@@ -25,7 +25,6 @@ > #include "Document.h" > #include "Event.h" > #include "SVGAnimatedStaticPropertyTearOff.h" >-#include "XLinkNames.h" > #include <wtf/IsoMallocInlines.h> > > namespace WebCore { >@@ -34,8 +33,8 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGScriptElement); > > inline SVGScriptElement::SVGScriptElement(const QualifiedName& tagName, Document& document, bool wasInsertedByParser, bool alreadyStarted) > : SVGElement(tagName, document) >- , SVGURIReference(*this) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGURIReference(this) > , ScriptElement(*this, wasInsertedByParser, alreadyStarted) > , m_svgLoadEventTimer(*this, &SVGElement::svgLoadEventTimerFired) > { >@@ -64,7 +63,7 @@ void SVGScriptElement::svgAttributeChanged(const QualifiedName& attrName) > } > > SVGElement::svgAttributeChanged(attrName); >- SVGExternalResourcesRequired::handleAttributeChange(attrName); >+ SVGExternalResourcesRequired::svgAttributeChanged(attrName); > } > > Node::InsertedIntoAncestorResult SVGScriptElement::insertedIntoAncestor(InsertionType insertionType, ContainerNode& parentOfInsertedTree) >diff --git a/Source/WebCore/svg/SVGScriptElement.h b/Source/WebCore/svg/SVGScriptElement.h >index 51b73d2334c..5264571facd 100644 >--- a/Source/WebCore/svg/SVGScriptElement.h >+++ b/Source/WebCore/svg/SVGScriptElement.h >@@ -27,10 +27,11 @@ > #include "SVGExternalResourcesRequired.h" > #include "SVGURIReference.h" > #include "ScriptElement.h" >+#include "XLinkNames.h" > > namespace WebCore { > >-class SVGScriptElement final : public SVGElement, public SVGURIReference, public SVGExternalResourcesRequired, public ScriptElement { >+class SVGScriptElement final : public SVGElement, public SVGExternalResourcesRequired, public SVGURIReference, public ScriptElement { > WTF_MAKE_ISO_ALLOCATED(SVGScriptElement); > public: > static Ref<SVGScriptElement> create(const QualifiedName&, Document&, bool wasInsertedByParser); >@@ -41,7 +42,7 @@ public: > private: > SVGScriptElement(const QualifiedName&, Document&, bool wasInsertedByParser, bool alreadyStarted); > >- using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGScriptElement, SVGElement, SVGURIReference, SVGExternalResourcesRequired>; >+ using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGScriptElement, SVGElement, SVGExternalResourcesRequired, SVGURIReference>; > > const SVGAttributeOwnerProxy& attributeOwnerProxy() const final { return m_attributeOwnerProxy; } > void parseAttribute(const QualifiedName&, const AtomicString&) final; >diff --git a/Source/WebCore/svg/SVGSwitchElement.cpp b/Source/WebCore/svg/SVGSwitchElement.cpp >index 6c1d0d93b68..989d435ba3f 100644 >--- a/Source/WebCore/svg/SVGSwitchElement.cpp >+++ b/Source/WebCore/svg/SVGSwitchElement.cpp >@@ -33,7 +33,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGSwitchElement); > > inline SVGSwitchElement::SVGSwitchElement(const QualifiedName& tagName, Document& document) > : SVGGraphicsElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > ASSERT(hasTagName(SVGNames::switchTag)); > } >diff --git a/Source/WebCore/svg/SVGSymbolElement.cpp b/Source/WebCore/svg/SVGSymbolElement.cpp >index 0d9920eb1f1..2e339a36b14 100644 >--- a/Source/WebCore/svg/SVGSymbolElement.cpp >+++ b/Source/WebCore/svg/SVGSymbolElement.cpp >@@ -33,8 +33,8 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGSymbolElement); > > inline SVGSymbolElement::SVGSymbolElement(const QualifiedName& tagName, Document& document) > : SVGElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >- , SVGFitToViewBox(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGFitToViewBox(this) > { > ASSERT(hasTagName(SVGNames::symbolTag)); > } >@@ -55,7 +55,6 @@ void SVGSymbolElement::svgAttributeChanged(const QualifiedName& attrName) > { > SVGElement::svgAttributeChanged(attrName); > SVGExternalResourcesRequired::svgAttributeChanged(attrName); >- SVGFitToViewBox::svgAttributeChanged(attrName); > } > > bool SVGSymbolElement::selfHasRelativeLengths() const >diff --git a/Source/WebCore/svg/SVGTRefElement.cpp b/Source/WebCore/svg/SVGTRefElement.cpp >index a7b54871d45..26becb225c7 100644 >--- a/Source/WebCore/svg/SVGTRefElement.cpp >+++ b/Source/WebCore/svg/SVGTRefElement.cpp >@@ -124,7 +124,7 @@ void SVGTRefTargetEventListener::handleEvent(ScriptExecutionContext&, Event& eve > > inline SVGTRefElement::SVGTRefElement(const QualifiedName& tagName, Document& document) > : SVGTextPositioningElement(tagName, document) >- , SVGURIReference(*this) >+ , SVGURIReference(this) > , m_targetListener(SVGTRefTargetEventListener::create(*this)) > { > ASSERT(hasTagName(SVGNames::trefTag)); >diff --git a/Source/WebCore/svg/SVGTests.cpp b/Source/WebCore/svg/SVGTests.cpp >index 70624827538..cc36dcba064 100644 >--- a/Source/WebCore/svg/SVGTests.cpp >+++ b/Source/WebCore/svg/SVGTests.cpp >@@ -191,19 +191,19 @@ void SVGTests::addSupportedAttributes(HashSet<QualifiedName>& supportedAttribute > supportedAttributes.add(systemLanguageAttr); > } > >-Ref<SVGStringList> SVGTests::requiredFeatures(SVGElement& contextElement) >+Ref<SVGStringList> SVGTests::requiredFeatures() > { > m_requiredFeatures.setShouldSynchronize(true); > return SVGStringList::create(m_contextElement, m_requiredFeatures.value()); > } > >-Ref<SVGStringList> SVGTests::requiredExtensions(SVGElement& contextElement) >+Ref<SVGStringList> SVGTests::requiredExtensions() > { > m_requiredExtensions.setShouldSynchronize(true); > return SVGStringList::create(m_contextElement, m_requiredExtensions.value()); > } > >-Ref<SVGStringList> SVGTests::systemLanguage(SVGElement& contextElement) >+Ref<SVGStringList> SVGTests::systemLanguage() > { > m_systemLanguage.setShouldSynchronize(true); > return SVGStringList::create(m_contextElement, m_systemLanguage.value()); >diff --git a/Source/WebCore/svg/SVGTests.h b/Source/WebCore/svg/SVGTests.h >index e1ecdedb24c..af25d250105 100644 >--- a/Source/WebCore/svg/SVGTests.h >+++ b/Source/WebCore/svg/SVGTests.h >@@ -36,6 +36,7 @@ template<typename OwnerType, typename... BaseTypes> > class SVGAttributeOwnerProxyImpl; > > class SVGTests { >+ WTF_MAKE_NONCOPYABLE(SVGTests); > public: > static bool hasExtension(const String&); > bool isValid() const; >@@ -57,7 +58,7 @@ public: > Ref<SVGStringList> systemLanguage(); > > protected: >- SVGTests(); >+ SVGTests(SVGElement* contextElement); > > private: > SVGElement& m_contextElement; >diff --git a/Source/WebCore/svg/SVGTextContentElement.cpp b/Source/WebCore/svg/SVGTextContentElement.cpp >index 644c006cfe1..8be560528de 100644 >--- a/Source/WebCore/svg/SVGTextContentElement.cpp >+++ b/Source/WebCore/svg/SVGTextContentElement.cpp >@@ -45,7 +45,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGTextContentElement); > > SVGTextContentElement::SVGTextContentElement(const QualifiedName& tagName, Document& document) > : SVGGraphicsElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >+ , SVGExternalResourcesRequired(this) > { > registerAttributes(); > } >diff --git a/Source/WebCore/svg/SVGTextContentElement.h b/Source/WebCore/svg/SVGTextContentElement.h >index 8c6652bc9f4..a18221f00e5 100644 >--- a/Source/WebCore/svg/SVGTextContentElement.h >+++ b/Source/WebCore/svg/SVGTextContentElement.h >@@ -85,13 +85,13 @@ public: > ExceptionOr<void> selectSubString(unsigned charnum, unsigned nchars); > > static SVGTextContentElement* elementFromRenderer(RenderObject*); >+ const SVGLengthValue& specifiedTextLength() { return m_specifiedTextLength; } > > using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGTextContentElement, SVGGraphicsElement, SVGExternalResourcesRequired>; > static AttributeOwnerProxy::AttributeRegistry& attributeRegistry() { return AttributeOwnerProxy::attributeRegistry(); } > >- const SVGLengthValue& specifiedTextLength() { return m_specifiedTextLength; } > const SVGLengthValue& textLength() const { return m_textLength.currentValue(); } >- const SVGLengthAdjustType& lengthAdjust() const { return m_lengthAdjust.currentValue(); } >+ SVGLengthAdjustType lengthAdjust() const { return m_lengthAdjust.currentValue(); } > > RefPtr<SVGAnimatedLength> textLengthAnimated() { return m_textLength.animatedProperty(); } > RefPtr<SVGAnimatedEnumeration> lengthAdjustAnimated() { return m_lengthAdjust.animatedProperty(); } >@@ -147,6 +147,8 @@ private: > SVGTextContentElement& m_element; > }; > >+ using SVGAnimatedCustomLengthAttributeAccessor = SVGAnimatedAttributeAccessor<SVGTextContentElement, SVGAnimatedCustomLengthAttribute, AnimatedLength>; >+ > AttributeOwnerProxy m_attributeOwnerProxy { *this }; > SVGAnimatedCustomLengthAttribute m_textLength { *this, m_attributeOwnerProxy, LengthModeOther }; > SVGAnimatedEnumerationAttribute<SVGLengthAdjustType> m_lengthAdjust { m_attributeOwnerProxy, SVGLengthAdjustSpacing }; >diff --git a/Source/WebCore/svg/SVGTextPathElement.cpp b/Source/WebCore/svg/SVGTextPathElement.cpp >index 08d7f625e2e..f922dabcbee 100644 >--- a/Source/WebCore/svg/SVGTextPathElement.cpp >+++ b/Source/WebCore/svg/SVGTextPathElement.cpp >@@ -36,7 +36,7 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGTextPathElement); > > inline SVGTextPathElement::SVGTextPathElement(const QualifiedName& tagName, Document& document) > : SVGTextContentElement(tagName, document) >- , SVGURIReference(*this) >+ , SVGURIReference(this) > { > ASSERT(hasTagName(SVGNames::textPathTag)); > registerAttributes(); >diff --git a/Source/WebCore/svg/SVGURIReference.cpp b/Source/WebCore/svg/SVGURIReference.cpp >index a803e0e9e3e..c3b3fafa715 100644 >--- a/Source/WebCore/svg/SVGURIReference.cpp >+++ b/Source/WebCore/svg/SVGURIReference.cpp >@@ -30,8 +30,8 @@ > > namespace WebCore { > >-SVGURIReference::SVGURIReference(SVGElement& contextElement) >- : m_attributeOwnerProxy(std::make_unique<AttributeOwnerProxy>(*this, contextElement)) >+SVGURIReference::SVGURIReference(SVGElement* contextElement) >+ : m_attributeOwnerProxy(std::make_unique<AttributeOwnerProxy>(*this, *contextElement)) > , m_href(*m_attributeOwnerProxy) > { > registerAttributes(); >diff --git a/Source/WebCore/svg/SVGURIReference.h b/Source/WebCore/svg/SVGURIReference.h >index 66784be62dd..6848c203fd6 100644 >--- a/Source/WebCore/svg/SVGURIReference.h >+++ b/Source/WebCore/svg/SVGURIReference.h >@@ -34,6 +34,7 @@ template<typename OwnerType, typename... BaseTypes> > class SVGAttributeOwnerProxyImpl; > > class SVGURIReference { >+ WTF_MAKE_NONCOPYABLE(SVGURIReference); > public: > virtual ~SVGURIReference() = default; > >@@ -55,14 +56,14 @@ public: > } > > using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGURIReference>; >- using AttributeRegistry = AttributeOwnerProxy::AttributeRegistry; >+ using AttributeRegistry = SVGAttributeRegistry<SVGURIReference>; > static AttributeRegistry& attributeRegistry(); > > const String& href() const; > RefPtr<SVGAnimatedString> hrefAnimated(); > > protected: >- SVGURIReference(SVGElement& contextElement); >+ SVGURIReference(SVGElement* contextElement); > > static bool isKnownAttribute(const QualifiedName& attributeName); > >diff --git a/Source/WebCore/svg/SVGUseElement.cpp b/Source/WebCore/svg/SVGUseElement.cpp >index 19bd6186fb0..f12c7d0a88e 100644 >--- a/Source/WebCore/svg/SVGUseElement.cpp >+++ b/Source/WebCore/svg/SVGUseElement.cpp >@@ -48,8 +48,8 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGUseElement); > > inline SVGUseElement::SVGUseElement(const QualifiedName& tagName, Document& document) > : SVGGraphicsElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >- , SVGURIReference(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGURIReference(this) > , m_svgLoadEventTimer(*this, &SVGElement::svgLoadEventTimerFired) > { > ASSERT(hasCustomStyleResolveCallbacks()); >@@ -154,8 +154,8 @@ void SVGUseElement::transferSizeAttributesToTargetClone(SVGElement& shadowElemen > // Spec (<use> on <svg>): If attributes width and/or height are provided on the 'use' element, then these > // values will override the corresponding attributes on the 'svg' in the generated tree. > auto correspondingElement = makeRefPtr(shadowElement.correspondingElement()); >- shadowElement.setAttribute(SVGNames::widthAttr, width().valueInSpecifiedUnits()) ? AtomicString(width().valueAsString() : (correspondingElement ? correspondingElement->getAttribute(SVGNames::widthAttr) : nullAtom())); >- shadowElement.setAttribute(SVGNames::heightAttr, height().valueInSpecifiedUnits()) ? AtomicString(height().valueAsString() : (correspondingElement ? correspondingElement->getAttribute(SVGNames::heightAttr) : nullAtom())); >+ shadowElement.setAttribute(SVGNames::widthAttr, width().valueInSpecifiedUnits() ? AtomicString(width().valueAsString()) : (correspondingElement ? correspondingElement->getAttribute(SVGNames::widthAttr) : nullAtom())); >+ shadowElement.setAttribute(SVGNames::heightAttr, height().valueInSpecifiedUnits() ? AtomicString(height().valueAsString()) : (correspondingElement ? correspondingElement->getAttribute(SVGNames::heightAttr) : nullAtom())); > } > } > >diff --git a/Source/WebCore/svg/SVGValue.h b/Source/WebCore/svg/SVGValue.h >index 499623d3df4..bf906179853 100644 >--- a/Source/WebCore/svg/SVGValue.h >+++ b/Source/WebCore/svg/SVGValue.h >@@ -35,7 +35,6 @@ > #include "SVGPathByteStream.h" > #include "SVGPointListValues.h" > #include "SVGPreserveAspectRatioValue.h" >-#include "SVGPropertyInfo.h" > #include "SVGPropertyTraits.h" > #include "SVGTransformListValues.h" > >diff --git a/Source/WebCore/svg/SVGViewElement.cpp b/Source/WebCore/svg/SVGViewElement.cpp >index 30eed4b1283..801d288234a 100644 >--- a/Source/WebCore/svg/SVGViewElement.cpp >+++ b/Source/WebCore/svg/SVGViewElement.cpp >@@ -32,13 +32,12 @@ WTF_MAKE_ISO_ALLOCATED_IMPL(SVGViewElement); > > inline SVGViewElement::SVGViewElement(const QualifiedName& tagName, Document& document) > : SVGElement(tagName, document) >- , SVGExternalResourcesRequired(*this) >- , SVGFitToViewBox(*this) >- , SVGZoomAndPan(*this) >+ , SVGExternalResourcesRequired(this) >+ , SVGFitToViewBox(this) >+ , SVGZoomAndPan(this) > , m_viewTarget(SVGNames::viewTargetAttr) > { > ASSERT(hasTagName(SVGNames::viewTag)); >- registerAnimatedPropertiesForSVGViewElement(); > } > > Ref<SVGViewElement> SVGViewElement::create(const QualifiedName& tagName, Document& document) >diff --git a/Source/WebCore/svg/SVGViewElement.h b/Source/WebCore/svg/SVGViewElement.h >index d65399e6670..a5773104dca 100644 >--- a/Source/WebCore/svg/SVGViewElement.h >+++ b/Source/WebCore/svg/SVGViewElement.h >@@ -45,7 +45,7 @@ private: > > // FIXME: svgAttributeChanged missing. > using AttributeOwnerProxy = SVGAttributeOwnerProxyImpl<SVGViewElement, SVGElement, SVGExternalResourcesRequired, SVGFitToViewBox, SVGZoomAndPan>; >- void parseAttribute(const QualifiedName&, const AtomicString&) final; >+ const SVGAttributeOwnerProxy& attributeOwnerProxy() const final { return m_attributeOwnerProxy; } > void parseAttribute(const QualifiedName&, const AtomicString&) final; > > bool rendererIsNeeded(const RenderStyle&) final { return false; } >diff --git a/Source/WebCore/svg/SVGViewSpec.cpp b/Source/WebCore/svg/SVGViewSpec.cpp >index e4a6a837bde..0f2f7d987dc 100644 >--- a/Source/WebCore/svg/SVGViewSpec.cpp >+++ b/Source/WebCore/svg/SVGViewSpec.cpp >@@ -33,8 +33,8 @@ > namespace WebCore { > > SVGViewSpec::SVGViewSpec(SVGElement& contextElement) >- : SVGFitToViewBox(contextElement, PropertyIsReadOnly) >- , SVGZoomAndPan(contextElement) >+ : SVGFitToViewBox(&contextElement, PropertyIsReadOnly) >+ , SVGZoomAndPan(&contextElement) > , m_contextElement(&contextElement) > , m_attributeOwnerProxy(*this, contextElement) > { >diff --git a/Source/WebCore/svg/SVGZoomAndPan.cpp b/Source/WebCore/svg/SVGZoomAndPan.cpp >index 2325d48786c..2b4413169d7 100644 >--- a/Source/WebCore/svg/SVGZoomAndPan.cpp >+++ b/Source/WebCore/svg/SVGZoomAndPan.cpp >@@ -24,8 +24,8 @@ > > namespace WebCore { > >-SVGZoomAndPan::SVGZoomAndPan(SVGElement& contextElement) >- : m_attributeOwnerProxy(*this, contextElement) >+SVGZoomAndPan::SVGZoomAndPan(SVGElement* contextElement) >+ : m_attributeOwnerProxy(*this, *contextElement) > { > registerAttributes(); > } >diff --git a/Source/WebCore/svg/SVGZoomAndPan.h b/Source/WebCore/svg/SVGZoomAndPan.h >index bf81434ee8e..d9bf861cc9b 100644 >--- a/Source/WebCore/svg/SVGZoomAndPan.h >+++ b/Source/WebCore/svg/SVGZoomAndPan.h >@@ -28,6 +28,7 @@ > namespace WebCore { > > class SVGZoomAndPan { >+ WTF_MAKE_NONCOPYABLE(SVGZoomAndPan); > public: > // Forward declare enumerations in the W3C naming scheme, for IDL generation. > enum { >@@ -47,7 +48,7 @@ public: > void parseAttribute(const QualifiedName&, const AtomicString&); > > protected: >- SVGZoomAndPan(SVGElement& contextElement); >+ SVGZoomAndPan(SVGElement* contextElement); > > static bool isKnownAttribute(const QualifiedName& attributeName) { return AttributeOwnerProxy::isKnownAttribute(attributeName); } > bool parseZoomAndPan(const UChar*&, const UChar*); >diff --git a/Source/WebCore/svg/properties/SVGAnimatedEnumerationPropertyTearOff.h b/Source/WebCore/svg/properties/SVGAnimatedEnumerationPropertyTearOff.h >index 413c2d36d44..5683af899b7 100644 >--- a/Source/WebCore/svg/properties/SVGAnimatedEnumerationPropertyTearOff.h >+++ b/Source/WebCore/svg/properties/SVGAnimatedEnumerationPropertyTearOff.h >@@ -27,6 +27,8 @@ namespace WebCore { > template<typename EnumType> > class SVGAnimatedEnumerationPropertyTearOff final : public SVGAnimatedStaticPropertyTearOff<unsigned> { > public: >+ using ContentType = EnumType; >+ > const unsigned& baseVal() final > { > const unsigned& baseVal = SVGAnimatedStaticPropertyTearOff::baseVal(); >diff --git a/Source/WebCore/svg/properties/SVGAnimatedPathSegListPropertyTearOff.cpp b/Source/WebCore/svg/properties/SVGAnimatedPathSegListPropertyTearOff.cpp >index d27968e8309..fd6e1f203a5 100644 >--- a/Source/WebCore/svg/properties/SVGAnimatedPathSegListPropertyTearOff.cpp >+++ b/Source/WebCore/svg/properties/SVGAnimatedPathSegListPropertyTearOff.cpp >@@ -48,7 +48,7 @@ void SVGAnimatedPathSegListPropertyTearOff::animValDidChange() > auto pathElement = makeRefPtr(downcast<SVGPathElement>(contextElement())); > > // If the animVal is observed from JS, we have to update it on each animation step. >- // This is an expensive operation and only done, if someone actually observes the animatedPathSegList() while an animation is running. >+ // This is an expensive operation and only done if someone actually observes the animatedPathSegList() while an animation is running. > if (pathElement->isAnimValObserved()) { > auto& animatedList = currentAnimatedValue(); > animatedList.clear(); >diff --git a/Source/WebCore/svg/properties/SVGAnimatedProperty.h b/Source/WebCore/svg/properties/SVGAnimatedProperty.h >index f671e69a0b8..8dc52dd11ed 100644 >--- a/Source/WebCore/svg/properties/SVGAnimatedProperty.h >+++ b/Source/WebCore/svg/properties/SVGAnimatedProperty.h >@@ -78,8 +78,8 @@ private: > using Cache = HashMap<SVGAnimatedPropertyDescription, SVGAnimatedProperty*, SVGAnimatedPropertyDescriptionHash, SVGAnimatedPropertyDescriptionHashTraits>; > static Cache& animatedPropertyCache() > { >- static NeverDestroyed<Cache> s_cache; >- return s_cache; >+ static NeverDestroyed<Cache> cache; >+ return cache; > } > > RefPtr<SVGElement> m_contextElement; >diff --git a/Source/WebCore/svg/properties/SVGAttributeAccessor.h b/Source/WebCore/svg/properties/SVGAttributeAccessor.h >index 832bf2a20fd..354c1dcc647 100644 >--- a/Source/WebCore/svg/properties/SVGAttributeAccessor.h >+++ b/Source/WebCore/svg/properties/SVGAttributeAccessor.h >@@ -69,10 +69,10 @@ protected: > > template<typename OwnerType, typename AttributeType> > class SVGPropertyAttributeAccessor : public SVGAttributeAccessor<OwnerType> { >+public: > using Base = SVGAttributeAccessor<OwnerType>; > using Base::m_attributeName; >- >-public: >+ > template<const LazyNeverDestroyed<const QualifiedName>& attributeName, AttributeType OwnerType::*attribute> > static SVGAttributeAccessor<OwnerType>& singleton() > { >@@ -107,6 +107,7 @@ protected: > > template<typename OwnerType, typename AnimatedAttributeType, AnimatedPropertyType type> > class SVGAnimatedAttributeAccessor : public SVGPropertyAttributeAccessor<OwnerType, AnimatedAttributeType> { >+public: > using PropertyTearOffType = typename AnimatedAttributeType::PropertyTearOffType; > using PropertyType = typename AnimatedAttributeType::PropertyType; > using Base = SVGPropertyAttributeAccessor<OwnerType, AnimatedAttributeType>; >@@ -115,7 +116,6 @@ class SVGAnimatedAttributeAccessor : public SVGPropertyAttributeAccessor<OwnerTy > using Base::m_attributeName; > using Base::m_identifier; > >-public: > template<const LazyNeverDestroyed<const QualifiedName>& attributeName, AnimatedAttributeType OwnerType::*attribute> > static SVGAttributeAccessor<OwnerType>& singleton() > { >@@ -169,15 +169,17 @@ protected: > > template<typename OwnerType, typename AnimatedAttributeType, AnimatedPropertyType type, typename SecondAnimatedAttributeType, AnimatedPropertyType secondType> > class SVGAnimatedPairAttributeAccessor : public SVGAnimatedAttributeAccessor<OwnerType, AnimatedAttributeType, type> { >+public: > using PropertyTearOffType = typename AnimatedAttributeType::PropertyTearOffType; > using SecondPropertyTearOffType = typename SecondAnimatedAttributeType::PropertyTearOffType; > using SecondPropertyType = typename SecondAnimatedAttributeType::PropertyType; > using Base = SVGAnimatedAttributeAccessor<OwnerType, AnimatedAttributeType, type>; > using Base::attribute; >+ using Base::lookupOrCreateAnimatedProperty; >+ using Base::lookupAnimatedProperty; > using Base::m_attributeName; > using Base::m_identifier; > >-public: > template< > const LazyNeverDestroyed<const QualifiedName>& attributeName, > const AtomicString& (*identifier)(), AnimatedAttributeType OwnerType::*attribute, >diff --git a/Source/WebCore/svg/properties/SVGAttributeRegistry.h b/Source/WebCore/svg/properties/SVGAttributeRegistry.h >index 17fe2a423c9..3022280063b 100644 >--- a/Source/WebCore/svg/properties/SVGAttributeRegistry.h >+++ b/Source/WebCore/svg/properties/SVGAttributeRegistry.h >@@ -160,6 +160,9 @@ public: > > bool isKnownAttribute(const QualifiedName& attributeName) const > { >+ // Here we need to loop through the entries in the map and use matches() to compare them with attributeName. >+ // m_map.contains() uses QualifiedName::operator==() which compares the impl pointers only while matches() >+ // compares the contents if the impl pointers differ. > auto it = std::find_if(m_map.begin(), m_map.end(), [&attributeName](const auto& entry) -> bool { > return entry.key.matches(attributeName); > }); >@@ -225,9 +228,9 @@ public: > } > > private: >- // It is a template function with parameter 'I' whose default value = 0. So you can call it without any parameter from animatedTypes(). >+ // This is a template function with parameter 'I' whose default value = 0. So you can call it without any parameter from animatedTypes(). > // It returns Vector<AnimatedPropertyType> and is enable_if<I == sizeof...(BaseTypes)>. So it is mainly for breaking the recursion. If >- // it is called this means no attribute was found in this registry for this QualifiedName. So return empty Vector<AnimatedPropertyType>. >+ // it is called, this means no attribute was found in this registry for this QualifiedName. So return an empty Vector<AnimatedPropertyType>. > template<size_t I = 0> > static typename std::enable_if<I == sizeof...(BaseTypes), Vector<AnimatedPropertyType>>::type animatedTypesBaseTypes(const QualifiedName&) { return { }; } > >diff --git a/Source/WebCore/svg/properties/SVGAttributeToPropertyMap.cpp b/Source/WebCore/svg/properties/SVGAttributeToPropertyMap.cpp >deleted file mode 100644 >index 9629e58ca27..00000000000 >--- a/Source/WebCore/svg/properties/SVGAttributeToPropertyMap.cpp >+++ /dev/null >@@ -1,86 +0,0 @@ >-/* >- * Copyright (C) Research In Motion Limited 2011. All rights reserved. >- * Copyright (C) 2015 Apple Inc. All rights reserved. >- * >- * This library is free software; you can redistribute it and/or >- * modify it under the terms of the GNU Library General Public >- * License as published by the Free Software Foundation; either >- * version 2 of the License, or (at your option) any later version. >- * >- * This library is distributed in the hope that it will be useful, >- * but WITHOUT ANY WARRANTY; without even the implied warranty of >- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU >- * Library General Public License for more details. >- * >- * You should have received a copy of the GNU Library General Public License >- * along with this library; see the file COPYING.LIB. If not, write to >- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, >- * Boston, MA 02110-1301, USA. >- */ >- >-#include "config.h" >-#include "SVGAttributeToPropertyMap.h" >- >-#include "SVGAnimatedProperty.h" >- >-namespace WebCore { >- >-void SVGAttributeToPropertyMap::addProperties(const SVGAttributeToPropertyMap& map) >-{ >- for (auto& vector : map.m_map.values()) { >- ASSERT(!vector.isEmpty()); >- auto& properties = m_map.add(vector[0]->attributeName, PropertyInfoVector()).iterator->value; >- properties.reserveCapacity(properties.size() + vector.size()); >- for (auto* property : vector) >- properties.uncheckedAppend(property); >- } >-} >- >-void SVGAttributeToPropertyMap::addProperty(const SVGPropertyInfo& info) >-{ >- m_map.add(info.attributeName, PropertyInfoVector()).iterator->value.append(&info); >-} >- >-Vector<RefPtr<SVGAnimatedProperty>> SVGAttributeToPropertyMap::properties(SVGElement& contextElement, const QualifiedName& attributeName) const >-{ >- Vector<RefPtr<SVGAnimatedProperty>> properties; >- auto it = m_map.find(attributeName); >- if (it == m_map.end()) >- return properties; >- properties.reserveInitialCapacity(it->value.size()); >- for (auto* property : it->value) >- properties.uncheckedAppend(property->lookupOrCreateWrapperForAnimatedProperty(&contextElement)); >- return properties; >-} >- >-Vector<AnimatedPropertyType> SVGAttributeToPropertyMap::types(const QualifiedName& attributeName) const >-{ >- Vector<AnimatedPropertyType> types; >- auto it = m_map.find(attributeName); >- if (it == m_map.end()) >- return types; >- types.reserveInitialCapacity(it->value.size()); >- for (auto* property : it->value) >- types.uncheckedAppend(property->animatedPropertyType); >- return types; >-} >- >-void SVGAttributeToPropertyMap::synchronizeProperties(SVGElement& contextElement) const >-{ >- for (auto& vector : m_map.values()) { >- for (auto* property : vector) >- property->synchronizeProperty(&contextElement); >- } >-} >- >-bool SVGAttributeToPropertyMap::synchronizeProperty(SVGElement& contextElement, const QualifiedName& attributeName) const >-{ >- auto it = m_map.find(attributeName); >- if (it == m_map.end()) >- return false; >- for (auto* property : it->value) >- property->synchronizeProperty(&contextElement); >- return true; >-} >- >-} >diff --git a/Source/WebCore/svg/properties/SVGAttributeToPropertyMap.h b/Source/WebCore/svg/properties/SVGAttributeToPropertyMap.h >deleted file mode 100644 >index 94768056a35..00000000000 >--- a/Source/WebCore/svg/properties/SVGAttributeToPropertyMap.h >+++ /dev/null >@@ -1,49 +0,0 @@ >-/* >- * Copyright (C) Research In Motion Limited 2011. All rights reserved. >- * Copyright (C) 2015 Apple Inc. All rights reserved. >- * >- * This library is free software; you can redistribute it and/or >- * modify it under the terms of the GNU Library General Public >- * License as published by the Free Software Foundation; either >- * version 2 of the License, or (at your option) any later version. >- * >- * This library is distributed in the hope that it will be useful, >- * but WITHOUT ANY WARRANTY; without even the implied warranty of >- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU >- * Library General Public License for more details. >- * >- * You should have received a copy of the GNU Library General Public License >- * along with this library; see the file COPYING.LIB. If not, write to >- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, >- * Boston, MA 02110-1301, USA. >- */ >- >-#pragma once >- >-#include "SVGPropertyInfo.h" >-#include <wtf/HashMap.h> >- >-namespace WebCore { >- >-class SVGAnimatedProperty; >-class SVGElement; >- >-class SVGAttributeToPropertyMap { >-public: >- bool isEmpty() const { return m_map.isEmpty(); } >- >- void addProperty(const SVGPropertyInfo&); >- void addProperties(const SVGAttributeToPropertyMap&); >- >- Vector<RefPtr<SVGAnimatedProperty>> properties(SVGElement&, const QualifiedName& attributeName) const; >- Vector<AnimatedPropertyType> types(const QualifiedName& attributeName) const; >- >- void synchronizeProperties(SVGElement&) const; >- bool synchronizeProperty(SVGElement&, const QualifiedName& attributeName) const; >- >-private: >- typedef Vector<const SVGPropertyInfo*> PropertyInfoVector; >- HashMap<QualifiedName, PropertyInfoVector> m_map; >-}; >- >-} // namespace WebCore >diff --git a/Source/WebCore/svg/properties/SVGPropertyInfo.cpp b/Source/WebCore/svg/properties/SVGPropertyInfo.cpp >deleted file mode 100644 >index 45c862cd525..00000000000 >--- a/Source/WebCore/svg/properties/SVGPropertyInfo.cpp >+++ /dev/null >@@ -1,35 +0,0 @@ >-/* >- * Copyright (C) Research In Motion Limited 2011. All rights reserved. >- * >- * This library is free software; you can redistribute it and/or >- * modify it under the terms of the GNU Library General Public >- * License as published by the Free Software Foundation; either >- * version 2 of the License, or (at your option) any later version. >- * >- * This library is distributed in the hope that it will be useful, >- * but WITHOUT ANY WARRANTY; without even the implied warranty of >- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU >- * Library General Public License for more details. >- * >- * You should have received a copy of the GNU Library General Public License >- * along with this library; see the file COPYING.LIB. If not, write to >- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, >- * Boston, MA 02110-1301, USA. >- */ >- >-#include "config.h" >-#include "SVGPropertyInfo.h" >- >-namespace WebCore { >- >-SVGPropertyInfo::SVGPropertyInfo(AnimatedPropertyType newType, AnimatedPropertyState newState, const QualifiedName& newAttributeName, const AtomicString& newPropertyIdentifier, SynchronizeProperty newSynchronizeProperty, LookupOrCreateWrapperForAnimatedProperty newLookupOrCreateWrapperForAnimatedProperty) >- : animatedPropertyType(newType) >- , animatedPropertyState(newState) >- , attributeName(newAttributeName) >- , propertyIdentifier(newPropertyIdentifier) >- , synchronizeProperty(newSynchronizeProperty) >- , lookupOrCreateWrapperForAnimatedProperty(newLookupOrCreateWrapperForAnimatedProperty) >-{ >-} >- >-} // namespace >diff --git a/Source/WebCore/svg/properties/SVGPropertyInfo.h b/Source/WebCore/svg/properties/SVGPropertyInfo.h >deleted file mode 100644 >index e1d5292dbc4..00000000000 >--- a/Source/WebCore/svg/properties/SVGPropertyInfo.h >+++ /dev/null >@@ -1,75 +0,0 @@ >-/* >- * Copyright (C) Research In Motion Limited 2011. All rights reserved. >- * >- * This library is free software; you can redistribute it and/or >- * modify it under the terms of the GNU Library General Public >- * License as published by the Free Software Foundation; either >- * version 2 of the License, or (at your option) any later version. >- * >- * This library is distributed in the hope that it will be useful, >- * but WITHOUT ANY WARRANTY; without even the implied warranty of >- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU >- * Library General Public License for more details. >- * >- * You should have received a copy of the GNU Library General Public License >- * along with this library; see the file COPYING.LIB. If not, write to >- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, >- * Boston, MA 02110-1301, USA. >- */ >- >-#pragma once >- >-#include "QualifiedName.h" >- >-namespace WebCore { >- >-class SVGAnimatedProperty; >-class SVGElement; >- >-enum AnimatedPropertyState { >- PropertyIsReadWrite, >- PropertyIsReadOnly >-}; >- >-enum AnimatedPropertyType { >- AnimatedPropertyTypeMin = 0, >- AnimatedAngle = AnimatedPropertyTypeMin, >- AnimatedBoolean, >- AnimatedColor, >- AnimatedEnumeration, >- AnimatedInteger, >- AnimatedIntegerOptionalInteger, >- AnimatedLength, >- AnimatedLengthList, >- AnimatedNumber, >- AnimatedNumberList, >- AnimatedNumberOptionalNumber, >- AnimatedPath, >- AnimatedPoints, >- AnimatedPreserveAspectRatio, >- AnimatedRect, >- AnimatedString, >- AnimatedTransformList, >- AnimatedPropertyTypeMax, >- AnimatedUnknown = AnimatedPropertyTypeMax >-}; >- >-struct SVGPropertyInfo { >- WTF_MAKE_FAST_ALLOCATED; >-public: >- typedef void (*SynchronizeProperty)(SVGElement*); >- typedef Ref<SVGAnimatedProperty> (*LookupOrCreateWrapperForAnimatedProperty)(SVGElement*); >- >- SVGPropertyInfo(AnimatedPropertyType newType, AnimatedPropertyState newState, const QualifiedName& newAttributeName, >- const AtomicString& newPropertyIdentifier, SynchronizeProperty newSynchronizeProperty, >- LookupOrCreateWrapperForAnimatedProperty newLookupOrCreateWrapperForAnimatedProperty); >- >- AnimatedPropertyType animatedPropertyType; >- AnimatedPropertyState animatedPropertyState; >- const QualifiedName& attributeName; >- const AtomicString& propertyIdentifier; >- SynchronizeProperty synchronizeProperty; >- LookupOrCreateWrapperForAnimatedProperty lookupOrCreateWrapperForAnimatedProperty; >-}; >- >-} // namespace WebCore
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 186751
:
342916
|
342917
|
342985
|
343001
|
343114
|
343123
|
343124
|
343127
|
343129
|
343162
|
343167
|
343169
|
343171
|
343174
|
343213
|
343217
|
343327
|
343335
|
343338
|
343339
|
343343
|
343415
|
343979
|
343989
|
344002
|
344513
|
344516
|
344523
|
344534
|
344536
|
344988
|
344990
|
346097
|
346103
|
346124
|
346129
|
346177
|
346179
|
346180
|
346182
|
346185
|
346188
|
346190
|
346192
|
346193
|
346197
|
346199
|
346201
|
346202
|
346203
|
346204
|
346205
|
346206
|
346207
|
346211
|
346212
|
346217
|
346224
|
346230
|
346233
|
346241
|
346244
|
346245
|
346315
|
346316
|
346317
|
346318
|
346319
|
346320
|
346322
|
346323
|
346324
|
346325
|
346326
|
346327
|
346328
|
346329
|
346330
|
346331
|
346332
|
346333
|
346334
|
346335
|
346336
|
346337
|
346338
|
346339
|
346340
|
346341
|
346342
|
346343
|
346344
|
346345
|
346346
|
346347
|
346348
|
346349
|
346350
|
346518
|
346519
|
346520
|
346521
|
346522
|
346524
|
346525
|
346526
|
346527
|
346528
|
346529
|
346530
|
346531
|
346532
|
346533
|
346534
|
346535
|
346536
|
346537
|
346538
|
346539
|
346540
|
346541
|
346545
|
346546
|
346549
|
346551
|
346552
|
346601
|
346602
|
346611
|
346636
|
346642