Title: [273680] trunk/Source/WebCore
- Revision
- 273680
- Author
- [email protected]
- Date
- 2021-03-01 12:37:41 -0800 (Mon, 01 Mar 2021)
Log Message
Remove added element from Style::Update root set
https://bugs.webkit.org/show_bug.cgi?id=222536
Reviewed by Zalan Bujtas.
With combined text and element updates an element might already exist in the root set when added.
Remove it from the root set to avoid updating it twice.
* style/StyleUpdate.cpp:
(WebCore::Style::Update::addElement):
(WebCore::Style::Update::addText):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (273679 => 273680)
--- trunk/Source/WebCore/ChangeLog 2021-03-01 20:26:16 UTC (rev 273679)
+++ trunk/Source/WebCore/ChangeLog 2021-03-01 20:37:41 UTC (rev 273680)
@@ -1,3 +1,17 @@
+2021-03-01 Antti Koivisto <[email protected]>
+
+ Remove added element from Style::Update root set
+ https://bugs.webkit.org/show_bug.cgi?id=222536
+
+ Reviewed by Zalan Bujtas.
+
+ With combined text and element updates an element might already exist in the root set when added.
+ Remove it from the root set to avoid updating it twice.
+
+ * style/StyleUpdate.cpp:
+ (WebCore::Style::Update::addElement):
+ (WebCore::Style::Update::addText):
+
2021-03-01 Yusuke Suzuki <[email protected]>
[JSC] Throw TypeError when getFunctionRealm hits revoked Proxy
Modified: trunk/Source/WebCore/style/StyleUpdate.cpp (273679 => 273680)
--- trunk/Source/WebCore/style/StyleUpdate.cpp 2021-03-01 20:26:16 UTC (rev 273679)
+++ trunk/Source/WebCore/style/StyleUpdate.cpp 2021-03-01 20:37:41 UTC (rev 273680)
@@ -90,7 +90,9 @@
ASSERT(!m_elements.contains(&element));
ASSERT(composedTreeAncestors(element).first() == parent);
+ m_roots.remove(&element);
addPossibleRoot(parent);
+
m_elements.add(&element, WTFMove(elementUpdates));
}
@@ -99,6 +101,7 @@
ASSERT(composedTreeAncestors(text).first() == parent);
addPossibleRoot(parent);
+
auto result = m_texts.ensure(&text, [&] {
return WTFMove(textUpdate);
});
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes