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

Unified Diff: Source/core/css/parser/BisonCSSParser-in.cpp

Issue 184693003: Merge SVGCSSParser into CSSPropertyParser.cpp (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Move isSystemColor to CSSPropertyParser for better reuse Created 6 years, 10 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
« no previous file with comments | « Source/core/core.gypi ('k') | Source/core/css/parser/CSSPropertyParser.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/parser/BisonCSSParser-in.cpp
diff --git a/Source/core/css/parser/BisonCSSParser-in.cpp b/Source/core/css/parser/BisonCSSParser-in.cpp
index a61ac69232619e0e456aa09820fd540f5f031faf..022c07e1831700fb36d38b0198e9c2a5de3bf986 100644
--- a/Source/core/css/parser/BisonCSSParser-in.cpp
+++ b/Source/core/css/parser/BisonCSSParser-in.cpp
@@ -1202,12 +1202,6 @@ bool BisonCSSParser::parseColor(const String& string)
return !m_parsedProperties.isEmpty() && m_parsedProperties.first().id() == CSSPropertyColor;
}
-// FIXME: This is copied from SVGCSSParser.cpp
-static bool isSystemColor(int id)
-{
- return (id >= CSSValueActiveborder && id <= CSSValueWindowtext) || id == CSSValueMenu;
-}
-
bool BisonCSSParser::parseSystemColor(RGBA32& color, const String& string, Document* document)
{
if (!document)
@@ -1216,7 +1210,7 @@ bool BisonCSSParser::parseSystemColor(RGBA32& color, const String& string, Docum
CSSParserString cssColor;
cssColor.init(string);
CSSValueID id = cssValueKeywordID(cssColor);
- if (!isSystemColor(id))
+ if (!CSSPropertyParser::isSystemColor(id))
return false;
Color parsedColor = RenderTheme::theme().systemColor(id);
« no previous file with comments | « Source/core/core.gypi ('k') | Source/core/css/parser/CSSPropertyParser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698