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

Side by Side Diff: third_party/WebKit/Source/core/css/CSSSelectorList.cpp

Issue 1575363006: Implement matching part of ::slotted() pseudo element (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@blink_slotted_parser
Patch Set: rebase 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008, 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2008, 2012 Apple Inc. All rights reserved.
3 * Copyright (C) 2009 Google Inc. All rights reserved. 3 * Copyright (C) 2009 Google Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 bool CSSSelectorList::selectorUsesDeepCombinatorOrShadowPseudo(size_t index) con st 178 bool CSSSelectorList::selectorUsesDeepCombinatorOrShadowPseudo(size_t index) con st
179 { 179 {
180 return forEachTagSelector([](const CSSSelector& selector) -> bool { 180 return forEachTagSelector([](const CSSSelector& selector) -> bool {
181 return selector.relation() == CSSSelector::ShadowDeep || selector.pseudo Type() == CSSSelector::PseudoShadow; 181 return selector.relation() == CSSSelector::ShadowDeep || selector.pseudo Type() == CSSSelector::PseudoShadow;
182 }, selectorAt(index)); 182 }, selectorAt(index));
183 } 183 }
184 184
185 bool CSSSelectorList::selectorNeedsUpdatedDistribution(size_t index) const 185 bool CSSSelectorList::selectorNeedsUpdatedDistribution(size_t index) const
186 { 186 {
187 return forEachTagSelector([](const CSSSelector& selector) -> bool { 187 return forEachTagSelector([](const CSSSelector& selector) -> bool {
188 return selector.relationIsAffectedByPseudoContent() || selector.pseudoTy pe() == CSSSelector::PseudoHostContext; 188 return selector.relationIsAffectedByPseudoContent() || selector.pseudoTy pe() == CSSSelector::PseudoSlotted || selector.pseudoType() == CSSSelector::Pseu doHostContext;
189 }, selectorAt(index)); 189 }, selectorAt(index));
190 } 190 }
191 191
192 } // namespace blink 192 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/css/CSSSelector.h ('k') | third_party/WebKit/Source/core/css/RuleFeature.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698