| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) | 3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) |
| 4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) | 4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) |
| 5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc.
All rights reserved. | 5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc.
All rights reserved. |
| 6 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> | 6 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> |
| 7 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> | 7 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> |
| 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
| 9 * Copyright (c) 2011, Code Aurora Forum. All rights reserved. | 9 * Copyright (c) 2011, Code Aurora Forum. All rights reserved. |
| 10 * Copyright (C) Research In Motion Limited 2011. All rights reserved. | 10 * Copyright (C) Research In Motion Limited 2011. All rights reserved. |
| (...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 91 | 91 |
| 92 struct MatchResult { | 92 struct MatchResult { |
| 93 MatchResult() | 93 MatchResult() |
| 94 : dynamicPseudo(NOPSEUDO) | 94 : dynamicPseudo(NOPSEUDO) |
| 95 , specificity(0) { } | 95 , specificity(0) { } |
| 96 | 96 |
| 97 PseudoId dynamicPseudo; | 97 PseudoId dynamicPseudo; |
| 98 unsigned specificity; | 98 unsigned specificity; |
| 99 }; | 99 }; |
| 100 | 100 |
| 101 template<typename SiblingTraversalStrategy> | 101 Match match(const SelectorCheckingContext&, MatchResult* = 0) const; |
| 102 Match match(const SelectorCheckingContext&, const SiblingTraversalStrategy&,
MatchResult* = 0) const; | 102 bool checkOne(const SelectorCheckingContext&, unsigned* specificity = 0) con
st; |
| 103 | |
| 104 template<typename SiblingTraversalStrategy> | |
| 105 bool checkOne(const SelectorCheckingContext&, const SiblingTraversalStrategy
&, unsigned* specificity = 0) const; | |
| 106 | 103 |
| 107 static bool matchesFocusPseudoClass(const Element&); | 104 static bool matchesFocusPseudoClass(const Element&); |
| 108 | 105 |
| 109 private: | 106 private: |
| 110 template<typename SiblingTraversalStrategy> | 107 Match matchForSubSelector(const SelectorCheckingContext&, MatchResult*) cons
t; |
| 111 Match matchForSubSelector(const SelectorCheckingContext&, const SiblingTrave
rsalStrategy&, MatchResult*) const; | 108 Match matchForRelation(const SelectorCheckingContext&, MatchResult*) const; |
| 112 template<typename SiblingTraversalStrategy> | 109 Match matchForShadowDistributed(const Element*, SelectorCheckingContext& nex
tContext, MatchResult* = 0) const; |
| 113 Match matchForRelation(const SelectorCheckingContext&, const SiblingTraversa
lStrategy&, MatchResult*) const; | 110 Match matchForPseudoShadow(const ContainerNode*, const SelectorCheckingConte
xt&, MatchResult*) const; |
| 114 template<typename SiblingTraversalStrategy> | 111 bool checkPseudoClass(const SelectorCheckingContext&, unsigned* specificity)
const; |
| 115 Match matchForShadowDistributed(const Element*, const SiblingTraversalStrate
gy&, SelectorCheckingContext& nextContext, MatchResult* = 0) const; | 112 bool checkPseudoElement(const SelectorCheckingContext&) const; |
| 116 template<typename SiblingTraversalStrategy> | |
| 117 Match matchForPseudoShadow(const ContainerNode*, const SelectorCheckingConte
xt&, const SiblingTraversalStrategy&, MatchResult*) const; | |
| 118 template<typename SiblingTraversalStrategy> | |
| 119 bool checkPseudoClass(const SelectorCheckingContext&, const SiblingTraversal
Strategy&, unsigned* specificity) const; | |
| 120 template<typename SiblingTraversalStrategy> | |
| 121 bool checkPseudoElement(const SelectorCheckingContext&, const SiblingTravers
alStrategy&) const; | |
| 122 | |
| 123 bool checkScrollbarPseudoClass(const SelectorCheckingContext&, Document*, co
nst CSSSelector&) const; | 113 bool checkScrollbarPseudoClass(const SelectorCheckingContext&, Document*, co
nst CSSSelector&) const; |
| 124 template<typename SiblingTraversalStrategy> | 114 bool checkPseudoHost(const SelectorCheckingContext&, unsigned*) const; |
| 125 bool checkPseudoHost(const SelectorCheckingContext&, const SiblingTraversalS
trategy&, unsigned*) const; | |
| 126 | 115 |
| 127 Mode m_mode; | 116 Mode m_mode; |
| 128 }; | 117 }; |
| 129 | 118 |
| 130 } | 119 } |
| 131 | 120 |
| 132 #endif | 121 #endif |
| OLD | NEW |