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

Unified Diff: third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.h

Issue 2378113005: Change isCSSWideKeyword() to take a StringView instead of a CSSValueID (Closed)
Patch Set: Created 4 years, 3 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: third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.h
diff --git a/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.h b/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.h
index 013863d20c38858506a07bd87b5ab704156c9ed0..ac5766c75d526f323381ffdd6a214ae0f1f6d97d 100644
--- a/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.h
+++ b/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.h
@@ -69,6 +69,8 @@ enum class ConsumeGeneratedImage {
CSSValue* consumeImage(CSSParserTokenRange&, CSSParserContext, ConsumeGeneratedImage = ConsumeGeneratedImage::Allow);
CSSValue* consumeImageOrNone(CSSParserTokenRange&, CSSParserContext);
+bool isCSSWideKeyword(StringView);
+
// Template implementations are at the bottom of the file for readability.
template<typename... emptyBaseCase> inline bool identMatches(CSSValueID id) { return false; }
@@ -84,11 +86,6 @@ template<CSSValueID... names> CSSPrimitiveValue* consumeIdent(CSSParserTokenRang
return CSSPrimitiveValue::createIdentifier(range.consumeIncludingWhitespace().id());
}
-static inline bool isCSSWideKeyword(const CSSValueID& id)
-{
- return id == CSSValueInitial || id == CSSValueInherit || id == CSSValueUnset || id == CSSValueDefault;
-}
-
} // namespace CSSPropertyParserHelpers
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698