Title: [259491] branches/safari-609.2.1.2-branch/Source/WebCore
- Revision
- 259491
- Author
- [email protected]
- Date
- 2020-04-03 12:57:47 -0700 (Fri, 03 Apr 2020)
Log Message
Cherry-pick r258464. rdar://problem/61231891
Call SVGTRefElement::buildPendingResource in SVGElement::didFinishInsertingNode
https://bugs.webkit.org/show_bug.cgi?id=208981
Reviewed by Antti Koivisto.
This patch moves the call to SVGTRefElement::buildPendingResource from SVGElement::insertedIntoAncestor
to SVGElement::didFinishInsertingNode.
* svg/SVGElement.cpp:
(WebCore::SVGElement::insertedIntoAncestor): Return true when the element has a pending resource ID.
(WebCore::SVGElement::didFinishInsertingNode): Added. Calls buildPendingResourcesIfNeeded.
* svg/SVGElement.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@258464 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Modified Paths
Diff
Modified: branches/safari-609.2.1.2-branch/Source/WebCore/ChangeLog (259490 => 259491)
--- branches/safari-609.2.1.2-branch/Source/WebCore/ChangeLog 2020-04-03 19:57:44 UTC (rev 259490)
+++ branches/safari-609.2.1.2-branch/Source/WebCore/ChangeLog 2020-04-03 19:57:47 UTC (rev 259491)
@@ -1,5 +1,40 @@
2020-04-03 Alan Coon <[email protected]>
+ Cherry-pick r258464. rdar://problem/61231891
+
+ Call SVGTRefElement::buildPendingResource in SVGElement::didFinishInsertingNode
+ https://bugs.webkit.org/show_bug.cgi?id=208981
+
+ Reviewed by Antti Koivisto.
+
+ This patch moves the call to SVGTRefElement::buildPendingResource from SVGElement::insertedIntoAncestor
+ to SVGElement::didFinishInsertingNode.
+
+ * svg/SVGElement.cpp:
+ (WebCore::SVGElement::insertedIntoAncestor): Return true when the element has a pending resource ID.
+ (WebCore::SVGElement::didFinishInsertingNode): Added. Calls buildPendingResourcesIfNeeded.
+ * svg/SVGElement.h:
+
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@258464 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2020-03-14 Ryosuke Niwa <[email protected]>
+
+ Call SVGTRefElement::buildPendingResource in SVGElement::didFinishInsertingNode
+ https://bugs.webkit.org/show_bug.cgi?id=208981
+
+ Reviewed by Antti Koivisto.
+
+ This patch moves the call to SVGTRefElement::buildPendingResource from SVGElement::insertedIntoAncestor
+ to SVGElement::didFinishInsertingNode.
+
+ * svg/SVGElement.cpp:
+ (WebCore::SVGElement::insertedIntoAncestor): Return true when the element has a pending resource ID.
+ (WebCore::SVGElement::didFinishInsertingNode): Added. Calls buildPendingResourcesIfNeeded.
+ * svg/SVGElement.h:
+
+2020-04-03 Alan Coon <[email protected]>
+
Cherry-pick r258459. rdar://problem/61231983
SVGMatrix should have the access right of its owner SVGTransform always
Modified: branches/safari-609.2.1.2-branch/Source/WebCore/svg/SVGElement.cpp (259490 => 259491)
--- branches/safari-609.2.1.2-branch/Source/WebCore/svg/SVGElement.cpp 2020-04-03 19:57:44 UTC (rev 259490)
+++ branches/safari-609.2.1.2-branch/Source/WebCore/svg/SVGElement.cpp 2020-04-03 19:57:47 UTC (rev 259491)
@@ -838,10 +838,22 @@
{
StyledElement::insertedIntoAncestor(insertionType, parentOfInsertedTree);
updateRelativeLengthsInformation();
- buildPendingResourcesIfNeeded();
+
+ if (needsPendingResourceHandling() && insertionType.connectedToDocument && !isInShadowTree()) {
+ SVGDocumentExtensions& extensions = document().accessSVGExtensions();
+ String resourceId = getIdAttribute();
+ if (extensions.isIdOfPendingResource(resourceId))
+ return InsertedIntoAncestorResult::NeedsPostInsertionCallback;
+ }
+
return InsertedIntoAncestorResult::Done;
}
+void SVGElement::didFinishInsertingNode()
+{
+ buildPendingResourcesIfNeeded();
+}
+
void SVGElement::buildPendingResourcesIfNeeded()
{
if (!needsPendingResourceHandling() || !isConnected() || isInShadowTree())
Modified: branches/safari-609.2.1.2-branch/Source/WebCore/svg/SVGElement.h (259490 => 259491)
--- branches/safari-609.2.1.2-branch/Source/WebCore/svg/SVGElement.h 2020-04-03 19:57:44 UTC (rev 259490)
+++ branches/safari-609.2.1.2-branch/Source/WebCore/svg/SVGElement.h 2020-04-03 19:57:47 UTC (rev 259491)
@@ -164,6 +164,7 @@
bool isPresentationAttribute(const QualifiedName&) const override;
void collectStyleForPresentationAttribute(const QualifiedName&, const AtomString&, MutableStyleProperties&) override;
InsertedIntoAncestorResult insertedIntoAncestor(InsertionType, ContainerNode&) override;
+ void didFinishInsertingNode() override;
void removedFromAncestor(RemovalType, ContainerNode&) override;
void childrenChanged(const ChildChange&) override;
virtual bool selfHasRelativeLengths() const { return false; }
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes