Title: [266899] trunk/Source/WebCore
- Revision
- 266899
- Author
- wenson_hs...@apple.com
- Date
- 2020-09-10 17:01:43 -0700 (Thu, 10 Sep 2020)
Log Message
Address a post-commit review comment after r266887
https://bugs.webkit.org/show_bug.cgi?id=216257
Reviewed by Darin Adler.
Remove a check that currently makes us conditionally set `IsComputedStyleInvalidFlag` if there is a computed
style in rare data. There should be no change in behavior; this just makes the code a bit simpler.
* dom/Element.cpp:
(WebCore::Element::invalidateStyle):
(WebCore::Element::storeDisplayContentsStyle):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (266898 => 266899)
--- trunk/Source/WebCore/ChangeLog 2020-09-10 23:52:11 UTC (rev 266898)
+++ trunk/Source/WebCore/ChangeLog 2020-09-11 00:01:43 UTC (rev 266899)
@@ -1,3 +1,17 @@
+2020-09-10 Wenson Hsieh <wenson_hs...@apple.com>
+
+ Address a post-commit review comment after r266887
+ https://bugs.webkit.org/show_bug.cgi?id=216257
+
+ Reviewed by Darin Adler.
+
+ Remove a check that currently makes us conditionally set `IsComputedStyleInvalidFlag` if there is a computed
+ style in rare data. There should be no change in behavior; this just makes the code a bit simpler.
+
+ * dom/Element.cpp:
+ (WebCore::Element::invalidateStyle):
+ (WebCore::Element::storeDisplayContentsStyle):
+
2020-09-10 Chris Dumez <cdu...@apple.com>
Unreviewed, reverting r266842 and r266883.
Modified: trunk/Source/WebCore/dom/Element.cpp (266898 => 266899)
--- trunk/Source/WebCore/dom/Element.cpp 2020-09-10 23:52:11 UTC (rev 266898)
+++ trunk/Source/WebCore/dom/Element.cpp 2020-09-11 00:01:43 UTC (rev 266899)
@@ -1972,8 +1972,7 @@
// FIXME: This flag should be set whenever styles are invalidated while computed styles are present,
// not just in this codepath.
- if (hasRareData() && elementRareData()->computedStyle())
- setNodeFlag(NodeFlag::IsComputedStyleInvalidFlag);
+ setNodeFlag(NodeFlag::IsComputedStyleInvalidFlag);
}
void Element::invalidateStyleAndLayerComposition()
@@ -2024,6 +2023,7 @@
ASSERT(style && style->display() == DisplayType::Contents);
ASSERT(!renderer() || isPseudoElement());
ensureElementRareData().setComputedStyle(WTFMove(style));
+ clearNodeFlag(NodeFlag::IsComputedStyleInvalidFlag);
}
// Returns true is the given attribute is an event handler.
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes