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

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

Issue 192473003: Move CSSRuleList to the garbage collected heap (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: ager feedback Created 6 years, 9 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/css/CSSViewportRule.h ('k') | Source/core/css/ElementRuleCollector.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. 3 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved.
4 * 4 *
5 * This library is free software; you can redistribute it and/or 5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public 6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either 7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version. 8 * version 2 of the License, or (at your option) any later version.
9 * 9 *
10 * This library is distributed in the hope that it will be useful, 10 * This library is distributed in the hope that it will be useful,
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 95
96 void setMode(SelectorChecker::Mode mode) { m_mode = mode; } 96 void setMode(SelectorChecker::Mode mode) { m_mode = mode; }
97 void setPseudoStyleRequest(const PseudoStyleRequest& request) { m_pseudoStyl eRequest = request; } 97 void setPseudoStyleRequest(const PseudoStyleRequest& request) { m_pseudoStyl eRequest = request; }
98 void setSameOriginOnly(bool f) { m_sameOriginOnly = f; } 98 void setSameOriginOnly(bool f) { m_sameOriginOnly = f; }
99 99
100 void setMatchingUARules(bool matchingUARules) { m_matchingUARules = matching UARules; } 100 void setMatchingUARules(bool matchingUARules) { m_matchingUARules = matching UARules; }
101 bool hasAnyMatchingRules(RuleSet*); 101 bool hasAnyMatchingRules(RuleSet*);
102 102
103 MatchResult& matchedResult(); 103 MatchResult& matchedResult();
104 PassRefPtr<StyleRuleList> matchedStyleRuleList(); 104 PassRefPtr<StyleRuleList> matchedStyleRuleList();
105 PassRefPtr<CSSRuleList> matchedCSSRuleList(); 105 PassRefPtrWillBeRawPtr<CSSRuleList> matchedCSSRuleList();
106 106
107 void collectMatchingRules(const MatchRequest&, RuleRange&, SelectorChecker:: BehaviorAtBoundary = SelectorChecker::DoesNotCrossBoundary, CascadeScope = ignor eCascadeScope, CascadeOrder = ignoreCascadeOrder); 107 void collectMatchingRules(const MatchRequest&, RuleRange&, SelectorChecker:: BehaviorAtBoundary = SelectorChecker::DoesNotCrossBoundary, CascadeScope = ignor eCascadeScope, CascadeOrder = ignoreCascadeOrder);
108 void sortAndTransferMatchedRules(); 108 void sortAndTransferMatchedRules();
109 void clearMatchedRules(); 109 void clearMatchedRules();
110 void addElementStyleProperties(const StylePropertySet*, bool isCacheable = t rue); 110 void addElementStyleProperties(const StylePropertySet*, bool isCacheable = t rue);
111 111
112 unsigned lastMatchedRulesPosition() const { return m_matchedRules ? m_matche dRules->size() : 0; } 112 unsigned lastMatchedRulesPosition() const { return m_matchedRules ? m_matche dRules->size() : 0; }
113 void sortMatchedRulesFrom(unsigned position); 113 void sortMatchedRulesFrom(unsigned position);
114 void sortAndTransferMatchedRulesWithOnlySortBySpecificity(); 114 void sortAndTransferMatchedRulesWithOnlySortBySpecificity();
115 115
(...skipping 30 matching lines...) Expand all
146 146
147 PseudoStyleRequest m_pseudoStyleRequest; 147 PseudoStyleRequest m_pseudoStyleRequest;
148 SelectorChecker::Mode m_mode; 148 SelectorChecker::Mode m_mode;
149 bool m_canUseFastReject; 149 bool m_canUseFastReject;
150 bool m_sameOriginOnly; 150 bool m_sameOriginOnly;
151 bool m_matchingUARules; 151 bool m_matchingUARules;
152 152
153 OwnPtr<Vector<MatchedRule, 32> > m_matchedRules; 153 OwnPtr<Vector<MatchedRule, 32> > m_matchedRules;
154 154
155 // Output. 155 // Output.
156 RefPtr<StaticCSSRuleList> m_cssRuleList; 156 RefPtrWillBeMember<StaticCSSRuleList> m_cssRuleList;
157 RefPtr<StyleRuleList> m_styleRuleList; 157 RefPtr<StyleRuleList> m_styleRuleList;
158 MatchResult m_result; 158 MatchResult m_result;
159 }; 159 };
160 160
161 } // namespace WebCore 161 } // namespace WebCore
162 162
163 #endif // ElementRuleCollector_h 163 #endif // ElementRuleCollector_h
OLDNEW
« no previous file with comments | « Source/core/css/CSSViewportRule.h ('k') | Source/core/css/ElementRuleCollector.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698