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 20339e4018bc48d492006de8472ec94203540379..049b269a99f5e363fadc20a39271793451ab11b5 100644 |
--- a/third_party/WebKit/Source/core/css/SelectorChecker.cpp |
+++ b/third_party/WebKit/Source/core/css/SelectorChecker.cpp |
@@ -337,10 +337,6 @@ |
next_context.pseudo_id = kPseudoIdNone; |
switch (relation) { |
- case CSSSelector::kShadowDeepAsDescendant: |
- Deprecation::CountDeprecation(context.element->GetDocument(), |
- UseCounter::kCSSDeepCombinator); |
- // fall through |
case CSSSelector::kDescendant: |
if (context.selector->RelationIsAffectedByPseudoContent()) { |
for (Element* element = context.element; element; |
@@ -418,6 +414,10 @@ |
return kSelectorFailsAllSiblings; |
case CSSSelector::kShadowPseudo: { |
+ if (!is_ua_rule_ && mode_ != kQueryingRules && |
+ context.selector->GetPseudoType() == CSSSelector::kPseudoShadow) |
+ Deprecation::CountDeprecation(context.element->GetDocument(), |
+ UseCounter::kCSSSelectorPseudoShadow); |
// If we're in the same tree-scope as the scoping element, then following |
// a shadow descendant combinator would escape that and thus the scope. |
if (context.scope && context.scope->OwnerShadowHost() && |