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

Side by Side Diff: Source/core/css/CSSSelector.h

Issue 772103002: Collect content:attr(...)-features in RuleFeatureSet. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Avoid findPropertyIndex when possible. 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999-2003 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999-2003 Lars Knoll (knoll@kde.org)
3 * 1999 Waldo Bastian (bastian@kde.org) 3 * 1999 Waldo Bastian (bastian@kde.org)
4 * Copyright (C) 2004, 2006, 2007, 2008, 2009, 2010, 2013 Apple Inc. All rights reserved. 4 * Copyright (C) 2004, 2006, 2007, 2008, 2009, 2010, 2013 Apple Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 // the one in tagHistory(). For example, the CSS selector .a.b #c is represe nted as: 43 // the one in tagHistory(). For example, the CSS selector .a.b #c is represe nted as:
44 // 44 //
45 // selectorText(): .a.b #c 45 // selectorText(): .a.b #c
46 // --> (relation == Descendant) 46 // --> (relation == Descendant)
47 // selectorText(): .a.b 47 // selectorText(): .a.b
48 // --> (relation == SubSelector) 48 // --> (relation == SubSelector)
49 // selectorText(): .b 49 // selectorText(): .b
50 // 50 //
51 // The order of tagHistory() varies depending on the situation. 51 // The order of tagHistory() varies depending on the situation.
52 // * Relations using combinators (http://www.w3.org/TR/css3-selectors/#combi nators), such as descendant, sibling, etc., are parsed 52 // * Relations using combinators (http://www.w3.org/TR/css3-selectors/#combi nators), such as descendant, sibling, etc., are parsed
53 // right-to-left (in the example above, this is why .c is earlier in the t agHistory() chain than .a.b). 53 // right-to-left (in the example above, this is why #c is earlier in the t agHistory() chain than .a.b).
54 // * SubSelector relations are parsed left-to-right in most cases (such as t he .a.b example above); a counter-example is the 54 // * SubSelector relations are parsed left-to-right in most cases (such as t he .a.b example above); a counter-example is the
55 // ::content pseudo-element. Most (all?) other pseudo elements and pseudo classes are parsed left-to-right. 55 // ::content pseudo-element. Most (all?) other pseudo elements and pseudo classes are parsed left-to-right.
56 // * ShadowPseudo relations are parsed right-to-left. Example: summary::-web kit-details-marker is parsed as: 56 // * ShadowPseudo relations are parsed right-to-left. Example: summary::-web kit-details-marker is parsed as:
57 // selectorText(): summary::-webkit-details-marker 57 // selectorText(): summary::-webkit-details-marker
58 // --> (relation == ShadowPseudo) 58 // --> (relation == ShadowPseudo)
59 // selectorText(): summary 59 // selectorText(): summary
60 // 60 //
61 // ** match(): 61 // ** match():
62 // 62 //
63 // The match of the current simple selector tells us the type of selector, s uch as class, id, tagname, or pseudo-class. 63 // The match of the current simple selector tells us the type of selector, s uch as class, id, tagname, or pseudo-class.
(...skipping 477 matching lines...) Expand 10 before | Expand all | Expand 10 after
541 if (m_hasRareData) 541 if (m_hasRareData)
542 return m_data.m_rareData->m_value; 542 return m_data.m_rareData->m_value;
543 // AtomicString is really just a StringImpl* so the cast below is safe. 543 // AtomicString is really just a StringImpl* so the cast below is safe.
544 // FIXME: Perhaps call sites could be changed to accept StringImpl? 544 // FIXME: Perhaps call sites could be changed to accept StringImpl?
545 return *reinterpret_cast<const AtomicString*>(&m_data.m_value); 545 return *reinterpret_cast<const AtomicString*>(&m_data.m_value);
546 } 546 }
547 547
548 } // namespace blink 548 } // namespace blink
549 549
550 #endif // CSSSelector_h 550 #endif // CSSSelector_h
OLDNEW
« no previous file with comments | « LayoutTests/fast/css/invalidation/content-attr-style-mutation-expected.html ('k') | Source/core/css/RuleFeature.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698