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

Side by Side Diff: third_party/WebKit/Source/core/css/parser/CSSPropertyParser.h

Issue 2041363002: Move isColorKeyword out of CSSPropertyParser (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Alternative using StyleColor Created 4 years, 6 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2003 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2003 Lars Knoll (knoll@kde.org)
3 * Copyright (C) 2004, 2005, 2006, 2008, 2009, 2010 Apple Inc. All rights reserv ed. 3 * Copyright (C) 2004, 2005, 2006, 2008, 2009, 2010 Apple Inc. All rights reserv ed.
4 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> 4 * Copyright (C) 2008 Eric Seidel <eric@webkit.org>
5 * Copyright (C) 2009 - 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserve d. 5 * Copyright (C) 2009 - 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserve d.
6 * 6 *
7 * This library is free software; you can redistribute it and/or 7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public 8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either 9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version. 10 * version 2 of the License, or (at your option) any later version.
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 public: 42 public:
43 static bool parseValue(CSSPropertyID, bool important, 43 static bool parseValue(CSSPropertyID, bool important,
44 const CSSParserTokenRange&, const CSSParserContext&, 44 const CSSParserTokenRange&, const CSSParserContext&,
45 HeapVector<CSSProperty, 256>&, StyleRule::RuleType); 45 HeapVector<CSSProperty, 256>&, StyleRule::RuleType);
46 46
47 // Parses a non-shorthand CSS property 47 // Parses a non-shorthand CSS property
48 static CSSValue* parseSingleValue(CSSPropertyID, const CSSParserTokenRange&, const CSSParserContext&); 48 static CSSValue* parseSingleValue(CSSPropertyID, const CSSParserTokenRange&, const CSSParserContext&);
49 49
50 // TODO(timloh): This doesn't seem like the right place for these 50 // TODO(timloh): This doesn't seem like the right place for these
51 static bool isSystemColor(CSSValueID); 51 static bool isSystemColor(CSSValueID);
52 static bool isColorKeyword(CSSValueID);
53 static bool isValidNumericValue(double); 52 static bool isValidNumericValue(double);
54 53
55 private: 54 private:
56 CSSPropertyParser(const CSSParserTokenRange&, const CSSParserContext&, 55 CSSPropertyParser(const CSSParserTokenRange&, const CSSParserContext&,
57 HeapVector<CSSProperty, 256>*); 56 HeapVector<CSSProperty, 256>*);
58 57
59 // TODO(timloh): Rename once the CSSParserValue-based parseValue is removed 58 // TODO(timloh): Rename once the CSSParserValue-based parseValue is removed
60 bool parseValueStart(CSSPropertyID unresolvedProperty, bool important); 59 bool parseValueStart(CSSPropertyID unresolvedProperty, bool important);
61 bool consumeCSSWideKeyword(CSSPropertyID unresolvedProperty, bool important) ; 60 bool consumeCSSWideKeyword(CSSPropertyID unresolvedProperty, bool important) ;
62 CSSValue* parseSingleValue(CSSPropertyID, CSSPropertyID = CSSPropertyInvalid ); 61 CSSValue* parseSingleValue(CSSPropertyID, CSSPropertyID = CSSPropertyInvalid );
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 // Outputs: 106 // Outputs:
108 HeapVector<CSSProperty, 256>* m_parsedProperties; 107 HeapVector<CSSProperty, 256>* m_parsedProperties;
109 }; 108 };
110 109
111 CSSPropertyID unresolvedCSSPropertyID(StringView); 110 CSSPropertyID unresolvedCSSPropertyID(StringView);
112 CSSValueID cssValueKeywordID(StringView); 111 CSSValueID cssValueKeywordID(StringView);
113 112
114 } // namespace blink 113 } // namespace blink
115 114
116 #endif // CSSPropertyParser_h 115 #endif // CSSPropertyParser_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698