Title: [258267] trunk/Source/WebCore
- Revision
- 258267
- Author
- commit-qu...@webkit.org
- Date
- 2020-03-11 10:05:28 -0700 (Wed, 11 Mar 2020)
Log Message
Consolidate detachment of document timeline into Document::commonTeardown.
https://bugs.webkit.org/show_bug.cgi?id=208786
<rdar://problem/59936716>
Patch by Jack Lee <shihchieh_...@apple.com> on 2020-03-11
Reviewed by Ryosuke Niwa.
Move detachment of DocumentTimeline to Document::commonTeardown().
No new tests. Covered by existing document tests.
* dom/Document.cpp:
(WebCore::Document::removedLastRef):
(WebCore::Document::commonTeardown):
(WebCore::Document::prepareForDestruction):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (258266 => 258267)
--- trunk/Source/WebCore/ChangeLog 2020-03-11 16:50:10 UTC (rev 258266)
+++ trunk/Source/WebCore/ChangeLog 2020-03-11 17:05:28 UTC (rev 258267)
@@ -1,3 +1,20 @@
+2020-03-11 Jack Lee <shihchieh_...@apple.com>
+
+ Consolidate detachment of document timeline into Document::commonTeardown.
+ https://bugs.webkit.org/show_bug.cgi?id=208786
+ <rdar://problem/59936716>
+
+ Reviewed by Ryosuke Niwa.
+
+ Move detachment of DocumentTimeline to Document::commonTeardown().
+
+ No new tests. Covered by existing document tests.
+
+ * dom/Document.cpp:
+ (WebCore::Document::removedLastRef):
+ (WebCore::Document::commonTeardown):
+ (WebCore::Document::prepareForDestruction):
+
2020-03-11 Commit Queue <commit-qu...@webkit.org>
Unreviewed, reverting r258263.
Modified: trunk/Source/WebCore/dom/Document.cpp (258266 => 258267)
--- trunk/Source/WebCore/dom/Document.cpp 2020-03-11 16:50:10 UTC (rev 258266)
+++ trunk/Source/WebCore/dom/Document.cpp 2020-03-11 17:05:28 UTC (rev 258267)
@@ -773,7 +773,7 @@
#endif
decrementReferencingNodeCount();
} else {
- stopActiveDOMObjects();
+ commonTeardown();
#ifndef NDEBUG
m_inRemovedLastRefFunction = false;
m_deletionHasBegun = true;
@@ -799,6 +799,10 @@
m_highlightMap->clear();
m_pendingScrollEventTargetList = nullptr;
+
+ while (!m_timelines.computesEmpty())
+ m_timelines.begin()->detachFromDocument();
+ m_timeline = nullptr;
}
Element* Document::elementForAccessKey(const String& key)
@@ -2583,10 +2587,6 @@
detachFromFrame();
- while (!m_timelines.computesEmpty())
- m_timelines.begin()->detachFromDocument();
- m_timeline = nullptr;
-
#if ENABLE(CSS_PAINTING_API)
for (auto& scope : m_paintWorkletGlobalScopes.values())
scope->prepareForDestruction();
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes