Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(539)

Unified Diff: Source/core/css/RuleFeature.cpp

Issue 195093004: Use invalidation sets for some pseudo elements. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Added recalc count checks to tests. Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/css/RuleFeature.cpp
diff --git a/Source/core/css/RuleFeature.cpp b/Source/core/css/RuleFeature.cpp
index 32df831c40f09f1a4ba62e9e28b5eb67afcbfd2e..748d50f8aaf8f01f8c118f61feade5189908a0fd 100644
--- a/Source/core/css/RuleFeature.cpp
+++ b/Source/core/css/RuleFeature.cpp
@@ -52,6 +52,16 @@ static bool isSkippableComponentForInvalidation(const CSSSelector& selector)
|| selector.m_match == CSSSelector::Id
|| selector.isAttributeSelector())
return true;
+ if (selector.m_match == CSSSelector::PseudoElement) {
+ switch (selector.m_pseudoType) {
+ case CSSSelector::PseudoBefore:
+ case CSSSelector::PseudoAfter:
+ case CSSSelector::PseudoBackdrop:
+ return true;
+ default:
+ return false;
+ }
+ }
if (selector.m_match != CSSSelector::PseudoClass)
return false;
switch (selector.pseudoType()) {

Powered by Google App Engine
This is Rietveld 408576698