OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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/properties/CSSPropertyAPIWebkitTextEmphasisStyle.h" | 5 #include "core/css/properties/CSSPropertyAPIWebkitTextEmphasisStyle.h" |
6 | 6 |
7 #include "core/css/CSSStringValue.h" | 7 #include "core/css/CSSStringValue.h" |
8 #include "core/css/CSSValueList.h" | 8 #include "core/css/CSSValueList.h" |
9 #include "core/css/parser/CSSPropertyParserHelpers.h" | 9 #include "core/css/parser/CSSPropertyParserHelpers.h" |
10 | 10 |
11 namespace blink { | 11 namespace blink { |
12 | 12 |
13 const CSSValue* CSSPropertyAPIWebkitTextEmphasisStyle::parseSingleValue( | 13 const CSSValue* CSSPropertyAPIWebkitTextEmphasisStyle::parseSingleValue( |
14 CSSParserTokenRange& range, | 14 CSSParserTokenRange& range, |
15 const CSSParserContext& context) { | 15 const CSSParserContext* context) { |
16 CSSValueID id = range.peek().id(); | 16 CSSValueID id = range.peek().id(); |
17 if (id == CSSValueNone) | 17 if (id == CSSValueNone) |
18 return CSSPropertyParserHelpers::consumeIdent(range); | 18 return CSSPropertyParserHelpers::consumeIdent(range); |
19 | 19 |
20 if (CSSValue* textEmphasisStyle = | 20 if (CSSValue* textEmphasisStyle = |
21 CSSPropertyParserHelpers::consumeString(range)) | 21 CSSPropertyParserHelpers::consumeString(range)) |
22 return textEmphasisStyle; | 22 return textEmphasisStyle; |
23 | 23 |
24 CSSIdentifierValue* fill = | 24 CSSIdentifierValue* fill = |
25 CSSPropertyParserHelpers::consumeIdent<CSSValueFilled, CSSValueOpen>( | 25 CSSPropertyParserHelpers::consumeIdent<CSSValueFilled, CSSValueOpen>( |
(...skipping 14 matching lines...) Expand all Loading... |
40 return parsedValues; | 40 return parsedValues; |
41 } | 41 } |
42 if (fill) | 42 if (fill) |
43 return fill; | 43 return fill; |
44 if (shape) | 44 if (shape) |
45 return shape; | 45 return shape; |
46 return nullptr; | 46 return nullptr; |
47 } | 47 } |
48 | 48 |
49 } // namespace blink | 49 } // namespace blink |
OLD | NEW |