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

Unified Diff: sky/engine/core/css/SelectorChecker.cpp

Issue 803113004: Remove containsAttributeSelector() checks. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years 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 | « sky/engine/core/css/RuleSet.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/engine/core/css/SelectorChecker.cpp
diff --git a/sky/engine/core/css/SelectorChecker.cpp b/sky/engine/core/css/SelectorChecker.cpp
index 0839e84cf08eb55753a2dc6614cc644c5c451530..8050254cd6f45b01d4e61acf80b5a4fb96c18aea 100644
--- a/sky/engine/core/css/SelectorChecker.cpp
+++ b/sky/engine/core/css/SelectorChecker.cpp
@@ -208,7 +208,11 @@ bool SelectorChecker::checkOne(const SelectorCheckingContext& context) const
case CSSSelector::Contain:
case CSSSelector::Begin:
case CSSSelector::End:
- return anyAttributeMatches(element, selector.match(), selector);
+ if (anyAttributeMatches(element, selector.match(), selector)) {
+ if (m_mode == ResolvingStyle && context.elementStyle)
+ context.elementStyle->setUnique();
+ }
+ return false;
case CSSSelector::PseudoClass:
return checkPseudoClass(context);
// FIXME(sky): Remove pseudo elements completely.
« no previous file with comments | « sky/engine/core/css/RuleSet.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698