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/CSSParserFastPaths.h" | 6 #include "core/css/parser/CSSParserFastPaths.h" |
7 | 7 |
8 #include "core/StylePropertyShorthand.h" | 8 #include "core/StylePropertyShorthand.h" |
9 #include "core/css/CSSFunctionValue.h" | 9 #include "core/css/CSSFunctionValue.h" |
10 #include "core/css/CSSValuePool.h" | 10 #include "core/css/CSSValuePool.h" |
11 #include "core/css/parser/CSSParserIdioms.h" | 11 #include "core/css/parser/CSSParserIdioms.h" |
12 #include "core/css/parser/CSSParserString.h" | 12 #include "core/css/parser/CSSParserString.h" |
13 #include "core/css/parser/CSSPropertyParser.h" | 13 #include "core/css/parser/CSSPropertyParser.h" |
14 #include "core/html/parser/HTMLParserIdioms.h" | 14 #include "core/html/parser/HTMLParserIdioms.h" |
15 #include "platform/RuntimeEnabledFeatures.h" | 15 #include "platform/RuntimeEnabledFeatures.h" |
16 | 16 |
17 namespace blink { | 17 namespace blink { |
18 | 18 |
19 static inline bool isSimpleLengthPropertyID(CSSPropertyID propertyId, bool& acce
ptsNegativeNumbers) | 19 static inline bool isSimpleLengthPropertyID(CSSPropertyID propertyId, bool& acce
ptsNegativeNumbers) |
20 { | 20 { |
21 switch (propertyId) { | 21 switch (propertyId) { |
22 case CSSPropertyFontSize: | 22 case CSSPropertyFontSize: |
| 23 case CSSPropertyGridColumnGap: |
| 24 case CSSPropertyGridRowGap: |
23 case CSSPropertyHeight: | 25 case CSSPropertyHeight: |
24 case CSSPropertyWidth: | 26 case CSSPropertyWidth: |
25 case CSSPropertyMinHeight: | 27 case CSSPropertyMinHeight: |
26 case CSSPropertyMinWidth: | 28 case CSSPropertyMinWidth: |
27 case CSSPropertyPaddingBottom: | 29 case CSSPropertyPaddingBottom: |
28 case CSSPropertyPaddingLeft: | 30 case CSSPropertyPaddingLeft: |
29 case CSSPropertyPaddingRight: | 31 case CSSPropertyPaddingRight: |
30 case CSSPropertyPaddingTop: | 32 case CSSPropertyPaddingTop: |
31 case CSSPropertyWebkitLogicalWidth: | 33 case CSSPropertyWebkitLogicalWidth: |
32 case CSSPropertyWebkitLogicalHeight: | 34 case CSSPropertyWebkitLogicalHeight: |
(...skipping 972 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1005 if (isColorPropertyID(propertyID)) | 1007 if (isColorPropertyID(propertyID)) |
1006 return parseColor(string, parserMode); | 1008 return parseColor(string, parserMode); |
1007 if (RefPtrWillBeRawPtr<CSSValue> keyword = parseKeywordValue(propertyID, str
ing)) | 1009 if (RefPtrWillBeRawPtr<CSSValue> keyword = parseKeywordValue(propertyID, str
ing)) |
1008 return keyword.release(); | 1010 return keyword.release(); |
1009 if (RefPtrWillBeRawPtr<CSSValue> transform = parseSimpleTransform(propertyID
, string)) | 1011 if (RefPtrWillBeRawPtr<CSSValue> transform = parseSimpleTransform(propertyID
, string)) |
1010 return transform.release(); | 1012 return transform.release(); |
1011 return nullptr; | 1013 return nullptr; |
1012 } | 1014 } |
1013 | 1015 |
1014 } // namespace blink | 1016 } // namespace blink |
OLD | NEW |