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

Unified Diff: third_party/WebKit/Source/core/css/SelectorChecker.cpp

Issue 1605473002: Pseudo element ids != NOPSEUDO only in rightmost compound. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@complex-pseudoelm-20160118
Patch Set: Created 4 years, 11 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/css/SelectorChecker.cpp
diff --git a/third_party/WebKit/Source/core/css/SelectorChecker.cpp b/third_party/WebKit/Source/core/css/SelectorChecker.cpp
index 3b72243fdd7c400765bf48753e575aeafbe5e52d..6de86ec54df0cd76930ff7c0a95dc730962ca3c2 100644
--- a/third_party/WebKit/Source/core/css/SelectorChecker.cpp
+++ b/third_party/WebKit/Source/core/css/SelectorChecker.cpp
@@ -1039,17 +1039,13 @@ bool SelectorChecker::checkPseudoElement(const SelectorCheckingContext& context,
break;
}
- if (!context.inRightmostCompound && m_mode == ResolvingStyle)
- return false;
-
if (m_mode == QueryingRules)
return false;
+ if (m_mode == SharingRules)
+ return true;
- PseudoId pseudoId = CSSSelector::pseudoId(selector.pseudoType());
- if (pseudoId != NOPSEUDO && m_mode != SharingRules)
- result.dynamicPseudo = pseudoId;
-
- // ::before, ::after, etc.
+ result.dynamicPseudo = CSSSelector::pseudoId(selector.pseudoType());
+ ASSERT(result.dynamicPseudo != NOPSEUDO);
return true;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698