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

Unified Diff: Source/core/css/parser/CSSParserImpl.h

Issue 1018213004: CSS Parser: Mark on stylesheets whether the first rule was valid (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
Index: Source/core/css/parser/CSSParserImpl.h
diff --git a/Source/core/css/parser/CSSParserImpl.h b/Source/core/css/parser/CSSParserImpl.h
index cf1322b597b8b70767840be93e47db3c7bd23e0b..8cd1d11c9ca8d7d8321d236ae620cf850a99720d 100644
--- a/Source/core/css/parser/CSSParserImpl.h
+++ b/Source/core/css/parser/CSSParserImpl.h
@@ -18,6 +18,7 @@ namespace blink {
class StyleRule;
class StyleRuleBase;
+class StyleRuleCharset;
class StyleRuleFontFace;
class StyleRuleImport;
class StyleRuleKeyframe;
@@ -67,13 +68,15 @@ private:
KeyframesRuleList
};
+ // Returns whether the first encountered rule was valid
template<typename T>
- void consumeRuleList(CSSParserTokenRange, RuleListType, T callback);
+ bool consumeRuleList(CSSParserTokenRange, RuleListType, T callback);
// These two functions update the range they're given
PassRefPtrWillBeRawPtr<StyleRuleBase> consumeAtRule(CSSParserTokenRange&, AllowedRulesType);
PassRefPtrWillBeRawPtr<StyleRuleBase> consumeQualifiedRule(CSSParserTokenRange&, AllowedRulesType);
+ static PassRefPtrWillBeRawPtr<StyleRuleCharset> consumeCharsetRule(CSSParserTokenRange prelude);
PassRefPtrWillBeRawPtr<StyleRuleImport> consumeImportRule(CSSParserTokenRange prelude);
PassRefPtrWillBeRawPtr<StyleRuleNamespace> consumeNamespaceRule(CSSParserTokenRange prelude); // This can set m_defaultNamespace
PassRefPtrWillBeRawPtr<StyleRuleMedia> consumeMediaRule(CSSParserTokenRange prelude, CSSParserTokenRange block);
« no previous file with comments | « Source/core/css/invalidation/StyleSheetInvalidationAnalysis.cpp ('k') | Source/core/css/parser/CSSParserImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698