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

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

Issue 187353003: Implement /content/ combinator. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Patch for landing 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
« no previous file with comments | « Source/core/css/RuleSetTest.cpp ('k') | Source/core/css/SelectorFilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/SelectorChecker.cpp
diff --git a/Source/core/css/SelectorChecker.cpp b/Source/core/css/SelectorChecker.cpp
index 83687cb3f47969a7e089ebe09e8755192da85d0f..2f6f10fa0ad929a9ac820eecdf68d477ba54ef3f 100644
--- a/Source/core/css/SelectorChecker.cpp
+++ b/Source/core/css/SelectorChecker.cpp
@@ -138,9 +138,6 @@ SelectorChecker::Match SelectorChecker::match(const SelectorCheckingContext& con
if (context.selector->isCustomPseudoElement()) {
if (!matchesCustomPseudoElement(context.element, *context.selector))
return SelectorFailsLocally;
- } else if (context.selector->isContentPseudoElement()) {
- if (!context.element->isInShadowTree() || !context.element->isInsertionPoint())
- return SelectorFailsLocally;
} else {
if ((!context.elementStyle && m_mode == ResolvingStyle) || m_mode == QueryingRules)
return SelectorFailsLocally;
@@ -263,6 +260,10 @@ SelectorChecker::Match SelectorChecker::matchForRelation(const SelectorCheckingC
nextContext.elementStyle = 0;
return match(nextContext, siblingTraversalStrategy, result);
}
+
+ case CSSSelector::ShadowContent:
+ return matchForShadowDistributed(context.element, siblingTraversalStrategy, nextContext, result);
+
case CSSSelector::DirectAdjacent:
if (m_mode == ResolvingStyle) {
if (Node* parent = context.element->parentElementOrShadowRoot())
« no previous file with comments | « Source/core/css/RuleSetTest.cpp ('k') | Source/core/css/SelectorFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698