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

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

Issue 1192983003: CSS Custom Properties (Variables) (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: with missing files Created 5 years, 5 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
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 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 FNonNeg = 0x0400, 69 FNonNeg = 0x0400,
70 FUnitlessQuirk = 0x0800 70 FUnitlessQuirk = 0x0800
71 }; 71 };
72 72
73 static bool parseValue(CSSPropertyID, bool important, 73 static bool parseValue(CSSPropertyID, bool important,
74 CSSParserValueList*, const CSSParserContext&, 74 CSSParserValueList*, const CSSParserContext&,
75 WillBeHeapVector<CSSProperty, 256>&, StyleRule::Type); 75 WillBeHeapVector<CSSProperty, 256>&, StyleRule::Type);
76 76
77 static bool isSystemColor(int id); 77 static bool isSystemColor(int id);
78 78
79 static bool isVariableReference(CSSParserValue*);
80
79 private: 81 private:
80 CSSPropertyParser(CSSParserValueList*, const CSSParserContext&, 82 CSSPropertyParser(CSSParserValueList*, const CSSParserContext&,
81 WillBeHeapVector<CSSProperty, 256>&, StyleRule::Type); 83 WillBeHeapVector<CSSProperty, 256>&, StyleRule::Type);
82 84
83 bool parseValue(CSSPropertyID, bool important); 85 bool parseValue(CSSPropertyID, bool important);
84 86
85 bool inShorthand() const { return m_inParseShorthand; } 87 bool inShorthand() const { return m_inParseShorthand; }
86 bool inQuirksMode() const { return isQuirksModeBehavior(m_context.mode()); } 88 bool inQuirksMode() const { return isQuirksModeBehavior(m_context.mode()); }
87 89
88 bool parseViewportProperty(CSSPropertyID propId, bool important); 90 bool parseViewportProperty(CSSPropertyID propId, bool important);
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
265 bool parseFontFeatureTag(CSSValueList*); 267 bool parseFontFeatureTag(CSSValueList*);
266 PassRefPtrWillBeRawPtr<CSSValue> parseFontFeatureSettings(); 268 PassRefPtrWillBeRawPtr<CSSValue> parseFontFeatureSettings();
267 269
268 bool parseFontVariantLigatures(bool important); 270 bool parseFontVariantLigatures(bool important);
269 271
270 bool parseGeneratedImage(CSSParserValueList*, RefPtrWillBeRawPtr<CSSValue>&) ; 272 bool parseGeneratedImage(CSSParserValueList*, RefPtrWillBeRawPtr<CSSValue>&) ;
271 273
272 PassRefPtrWillBeRawPtr<CSSPrimitiveValue> createPrimitiveNumericValue(CSSPar serValue*); 274 PassRefPtrWillBeRawPtr<CSSPrimitiveValue> createPrimitiveNumericValue(CSSPar serValue*);
273 PassRefPtrWillBeRawPtr<CSSPrimitiveValue> createPrimitiveStringValue(CSSPars erValue*); 275 PassRefPtrWillBeRawPtr<CSSPrimitiveValue> createPrimitiveStringValue(CSSPars erValue*);
274 PassRefPtrWillBeRawPtr<CSSPrimitiveValue> createPrimitiveCustomIdentValue(CS SParserValue*); 276 PassRefPtrWillBeRawPtr<CSSPrimitiveValue> createPrimitiveCustomIdentValue(CS SParserValue*);
277 PassRefPtrWillBeRawPtr<CSSPrimitiveValue> createPrimitiveVariableReferenceVa lue(CSSParserValue*);
275 278
276 PassRefPtrWillBeRawPtr<CSSValue> createCSSImageValueWithReferrer(const Strin g& rawValue, const KURL&); 279 PassRefPtrWillBeRawPtr<CSSValue> createCSSImageValueWithReferrer(const Strin g& rawValue, const KURL&);
277 280
278 PassRefPtrWillBeRawPtr<CSSBasicShape> parseInsetRoundedCorners(PassRefPtrWil lBeRawPtr<CSSBasicShapeInset>, CSSParserValueList*); 281 PassRefPtrWillBeRawPtr<CSSBasicShape> parseInsetRoundedCorners(PassRefPtrWil lBeRawPtr<CSSBasicShapeInset>, CSSParserValueList*);
279 282
280 enum SizeParameterType { 283 enum SizeParameterType {
281 None, 284 None,
282 Auto, 285 Auto,
283 Length, 286 Length,
284 PageSize, 287 PageSize,
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
378 bool m_implicitShorthand; 381 bool m_implicitShorthand;
379 RefPtrWillBeMember<CSSCalcValue> m_parsedCalculation; 382 RefPtrWillBeMember<CSSCalcValue> m_parsedCalculation;
380 }; 383 };
381 384
382 CSSPropertyID unresolvedCSSPropertyID(const CSSParserString&); 385 CSSPropertyID unresolvedCSSPropertyID(const CSSParserString&);
383 CSSValueID cssValueKeywordID(const CSSParserString&); 386 CSSValueID cssValueKeywordID(const CSSParserString&);
384 387
385 } // namespace blink 388 } // namespace blink
386 389
387 #endif // CSSPropertyParser_h 390 #endif // CSSPropertyParser_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698