| OLD | NEW |
| (Empty) |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #include "config.h" | |
| 6 #include "core/css/parser/CSSParser.h" | |
| 7 | |
| 8 #include "core/css/CSSKeyframeRule.h" | |
| 9 #include "core/css/StyleColor.h" | |
| 10 #include "core/css/StyleRule.h" | |
| 11 | |
| 12 namespace blink { | |
| 13 | |
| 14 CSSParser::CSSParser(const CSSParserContext& context) | |
| 15 : m_bisonParser(context) | |
| 16 { | |
| 17 } | |
| 18 | |
| 19 bool CSSParser::parseDeclaration(MutableStylePropertySet* propertySet, const Str
ing& declaration, CSSParserObserver* observer, StyleSheetContents* styleSheet) | |
| 20 { | |
| 21 return m_bisonParser.parseDeclaration(propertySet, declaration, observer, st
yleSheet); | |
| 22 } | |
| 23 | |
| 24 void CSSParser::parseSelector(const String& selector, CSSSelectorList& selectorL
ist) | |
| 25 { | |
| 26 m_bisonParser.parseSelector(selector, selectorList); | |
| 27 } | |
| 28 | |
| 29 PassRefPtrWillBeRawPtr<StyleRuleBase> CSSParser::parseRule(const CSSParserContex
t& context, StyleSheetContents* styleSheet, const String& rule) | |
| 30 { | |
| 31 return BisonCSSParser(context).parseRule(styleSheet, rule); | |
| 32 } | |
| 33 | |
| 34 void CSSParser::parseSheet(const CSSParserContext& context, StyleSheetContents*
styleSheet, const String& text, const TextPosition& startPosition, CSSParserObse
rver* observer, bool logErrors) | |
| 35 { | |
| 36 BisonCSSParser(context).parseSheet(styleSheet, text, startPosition, observer
, logErrors); | |
| 37 } | |
| 38 | |
| 39 bool CSSParser::parseValue(MutableStylePropertySet* declaration, CSSPropertyID p
ropertyID, const String& string, bool important, CSSParserMode parserMode, Style
SheetContents* styleSheet) | |
| 40 { | |
| 41 return BisonCSSParser::parseValue(declaration, propertyID, string, important
, parserMode, styleSheet); | |
| 42 } | |
| 43 | |
| 44 bool CSSParser::parseValue(MutableStylePropertySet* declaration, CSSPropertyID p
ropertyID, const String& string, bool important, const Document& document) | |
| 45 { | |
| 46 return BisonCSSParser::parseValue(declaration, propertyID, string, important
, document); | |
| 47 } | |
| 48 | |
| 49 PassRefPtrWillBeRawPtr<ImmutableStylePropertySet> CSSParser::parseInlineStyleDec
laration(const String& styleString, Element* element) | |
| 50 { | |
| 51 return BisonCSSParser::parseInlineStyleDeclaration(styleString, element); | |
| 52 } | |
| 53 | |
| 54 PassOwnPtr<Vector<double> > CSSParser::parseKeyframeKeyList(const String& keyLis
t) | |
| 55 { | |
| 56 return BisonCSSParser(strictCSSParserContext()).parseKeyframeKeyList(keyList
); | |
| 57 } | |
| 58 | |
| 59 PassRefPtrWillBeRawPtr<StyleKeyframe> CSSParser::parseKeyframeRule(const CSSPars
erContext& context, StyleSheetContents* styleSheet, const String& rule) | |
| 60 { | |
| 61 return BisonCSSParser(context).parseKeyframeRule(styleSheet, rule); | |
| 62 } | |
| 63 | |
| 64 bool CSSParser::parseSupportsCondition(const String& condition) | |
| 65 { | |
| 66 return BisonCSSParser(CSSParserContext(HTMLStandardMode, 0)).parseSupportsCo
ndition(condition); | |
| 67 } | |
| 68 | |
| 69 PassRefPtr<CSSValueList> CSSParser::parseFontFaceValue(const AtomicString& fontF
ace) | |
| 70 { | |
| 71 return BisonCSSParser::parseFontFaceValue(fontFace); | |
| 72 } | |
| 73 | |
| 74 PassRefPtr<CSSValue> CSSParser::parseAnimationTimingFunctionValue(const String&
timingFunction) | |
| 75 { | |
| 76 return BisonCSSParser::parseAnimationTimingFunctionValue(timingFunction); | |
| 77 } | |
| 78 | |
| 79 bool CSSParser::parseColor(RGBA32& color, const String& string, bool strict) | |
| 80 { | |
| 81 return BisonCSSParser::parseColor(color, string, strict); | |
| 82 } | |
| 83 | |
| 84 StyleColor CSSParser::colorFromRGBColorString(const String& string) | |
| 85 { | |
| 86 return BisonCSSParser::colorFromRGBColorString(string); | |
| 87 } | |
| 88 | |
| 89 bool CSSParser::parseSystemColor(RGBA32& color, const String& colorString) | |
| 90 { | |
| 91 return BisonCSSParser::parseSystemColor(color, colorString); | |
| 92 } | |
| 93 | |
| 94 } // namespace blink | |
| OLD | NEW |