| 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 "core/css/parser/CSSParser.h" | 5 #include "core/css/parser/CSSParser.h" |
| 6 | 6 |
| 7 #include "core/css/CSSColorValue.h" | 7 #include "core/css/CSSColorValue.h" |
| 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" |
| 11 #include "core/css/StyleSheetContents.h" | 11 #include "core/css/StyleSheetContents.h" |
| 12 #include "core/css/parser/CSSParserFastPaths.h" | 12 #include "core/css/parser/CSSParserFastPaths.h" |
| 13 #include "core/css/parser/CSSParserImpl.h" | 13 #include "core/css/parser/CSSParserImpl.h" |
| 14 #include "core/css/parser/CSSPropertyParser.h" | 14 #include "core/css/parser/CSSPropertyParser.h" |
| 15 #include "core/css/parser/CSSSelectorParser.h" | 15 #include "core/css/parser/CSSSelectorParser.h" |
| 16 #include "core/css/parser/CSSSupportsParser.h" | 16 #include "core/css/parser/CSSSupportsParser.h" |
| 17 #include "core/css/parser/CSSTokenizer.h" | 17 #include "core/css/parser/CSSTokenizer.h" |
| 18 #include "core/css/parser/CSSVariableParser.h" | 18 #include "core/css/parser/CSSVariableParser.h" |
| 19 #include "core/layout/LayoutTheme.h" | 19 #include "core/layout/LayoutTheme.h" |
| 20 #include <memory> | 20 #include <memory> |
| 21 | 21 |
| 22 namespace blink { | 22 namespace blink { |
| 23 | 23 |
| 24 using namespace cssvalue; |
| 25 |
| 24 bool CSSParser::parseDeclarationList(const CSSParserContext* context, | 26 bool CSSParser::parseDeclarationList(const CSSParserContext* context, |
| 25 MutableStylePropertySet* propertySet, | 27 MutableStylePropertySet* propertySet, |
| 26 const String& declaration) { | 28 const String& declaration) { |
| 27 return CSSParserImpl::parseDeclarationList(propertySet, declaration, context); | 29 return CSSParserImpl::parseDeclarationList(propertySet, declaration, context); |
| 28 } | 30 } |
| 29 | 31 |
| 30 void CSSParser::parseDeclarationListForInspector( | 32 void CSSParser::parseDeclarationListForInspector( |
| 31 const CSSParserContext* context, | 33 const CSSParserContext* context, |
| 32 const String& declaration, | 34 const String& declaration, |
| 33 CSSParserObserver& observer) { | 35 CSSParserObserver& observer) { |
| (...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 242 builder.append(propertyValue); | 244 builder.append(propertyValue); |
| 243 builder.append("; }"); | 245 builder.append("; }"); |
| 244 StyleRuleBase* rule = parseRule(context, nullptr, builder.toString()); | 246 StyleRuleBase* rule = parseRule(context, nullptr, builder.toString()); |
| 245 if (!rule || !rule->isFontFaceRule()) | 247 if (!rule || !rule->isFontFaceRule()) |
| 246 return nullptr; | 248 return nullptr; |
| 247 return toStyleRuleFontFace(rule)->properties().getPropertyCSSValue( | 249 return toStyleRuleFontFace(rule)->properties().getPropertyCSSValue( |
| 248 propertyID); | 250 propertyID); |
| 249 } | 251 } |
| 250 | 252 |
| 251 } // namespace blink | 253 } // namespace blink |
| OLD | NEW |