| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "config.h" | 5 #include "config.h" |
| 6 #include "core/css/parser/CSSParser.h" | 6 #include "core/css/parser/CSSParser.h" |
| 7 | 7 |
| 8 #include "core/css/CSSKeyframeRule.h" | 8 #include "core/css/CSSKeyframeRule.h" |
| 9 #include "core/css/StyleColor.h" | 9 #include "core/css/StyleColor.h" |
| 10 #include "core/css/StyleRule.h" | 10 #include "core/css/StyleRule.h" |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 97 return stylePropertySet->getPropertyCSSValue(propertyID); | 97 return stylePropertySet->getPropertyCSSValue(propertyID); |
| 98 } | 98 } |
| 99 | 99 |
| 100 PassRefPtrWillBeRawPtr<ImmutableStylePropertySet> CSSParser::parseInlineStyleDec
laration(const String& styleString, Element* element) | 100 PassRefPtrWillBeRawPtr<ImmutableStylePropertySet> CSSParser::parseInlineStyleDec
laration(const String& styleString, Element* element) |
| 101 { | 101 { |
| 102 if (RuntimeEnabledFeatures::newCSSParserEnabled()) | 102 if (RuntimeEnabledFeatures::newCSSParserEnabled()) |
| 103 return CSSParserImpl::parseInlineStyleDeclaration(styleString, element); | 103 return CSSParserImpl::parseInlineStyleDeclaration(styleString, element); |
| 104 return BisonCSSParser::parseInlineStyleDeclaration(styleString, element); | 104 return BisonCSSParser::parseInlineStyleDeclaration(styleString, element); |
| 105 } | 105 } |
| 106 | 106 |
| 107 PassOwnPtr<Vector<double> > CSSParser::parseKeyframeKeyList(const String& keyLis
t) | 107 PassOwnPtr<Vector<double>> CSSParser::parseKeyframeKeyList(const String& keyList
) |
| 108 { | 108 { |
| 109 if (RuntimeEnabledFeatures::newCSSParserEnabled()) | 109 if (RuntimeEnabledFeatures::newCSSParserEnabled()) |
| 110 return CSSParserImpl::parseKeyframeKeyList(keyList); | 110 return CSSParserImpl::parseKeyframeKeyList(keyList); |
| 111 return BisonCSSParser(strictCSSParserContext()).parseKeyframeKeyList(keyList
); | 111 return BisonCSSParser(strictCSSParserContext()).parseKeyframeKeyList(keyList
); |
| 112 } | 112 } |
| 113 | 113 |
| 114 PassRefPtrWillBeRawPtr<StyleRuleKeyframe> CSSParser::parseKeyframeRule(const CSS
ParserContext& context, StyleSheetContents* styleSheet, const String& rule) | 114 PassRefPtrWillBeRawPtr<StyleRuleKeyframe> CSSParser::parseKeyframeRule(const CSS
ParserContext& context, StyleSheetContents* styleSheet, const String& rule) |
| 115 { | 115 { |
| 116 if (RuntimeEnabledFeatures::newCSSParserEnabled()) { | 116 if (RuntimeEnabledFeatures::newCSSParserEnabled()) { |
| 117 RefPtrWillBeRawPtr<StyleRuleBase> keyframe = CSSParserImpl::parseRule(ru
le, context, CSSParserImpl::KeyframeRules); | 117 RefPtrWillBeRawPtr<StyleRuleBase> keyframe = CSSParserImpl::parseRule(ru
le, context, CSSParserImpl::KeyframeRules); |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 175 CSSValueID id = cssValueKeywordID(cssColor); | 175 CSSValueID id = cssValueKeywordID(cssColor); |
| 176 if (!CSSPropertyParser::isSystemColor(id)) | 176 if (!CSSPropertyParser::isSystemColor(id)) |
| 177 return false; | 177 return false; |
| 178 | 178 |
| 179 Color parsedColor = LayoutTheme::theme().systemColor(id); | 179 Color parsedColor = LayoutTheme::theme().systemColor(id); |
| 180 color = parsedColor.rgb(); | 180 color = parsedColor.rgb(); |
| 181 return true; | 181 return true; |
| 182 } | 182 } |
| 183 | 183 |
| 184 } // namespace blink | 184 } // namespace blink |
| OLD | NEW |