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/CSSTransformValue.h" | 9 #include "core/css/CSSTransformValue.h" |
10 #include "core/css/CSSValuePool.h" | 10 #include "core/css/CSSValuePool.h" |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 case CSSPropertyMarginBottom: | 43 case CSSPropertyMarginBottom: |
44 case CSSPropertyMarginLeft: | 44 case CSSPropertyMarginLeft: |
45 case CSSPropertyMarginRight: | 45 case CSSPropertyMarginRight: |
46 case CSSPropertyMarginTop: | 46 case CSSPropertyMarginTop: |
47 case CSSPropertyRight: | 47 case CSSPropertyRight: |
48 case CSSPropertyTop: | 48 case CSSPropertyTop: |
49 case CSSPropertyWebkitMarginAfter: | 49 case CSSPropertyWebkitMarginAfter: |
50 case CSSPropertyWebkitMarginBefore: | 50 case CSSPropertyWebkitMarginBefore: |
51 case CSSPropertyWebkitMarginEnd: | 51 case CSSPropertyWebkitMarginEnd: |
52 case CSSPropertyWebkitMarginStart: | 52 case CSSPropertyWebkitMarginStart: |
| 53 case CSSPropertyX: |
| 54 case CSSPropertyY: |
53 acceptsNegativeNumbers = true; | 55 acceptsNegativeNumbers = true; |
54 return true; | 56 return true; |
55 default: | 57 default: |
56 return false; | 58 return false; |
57 } | 59 } |
58 } | 60 } |
59 | 61 |
60 template <typename CharacterType> | 62 template <typename CharacterType> |
61 static inline bool parseSimpleLength(const CharacterType* characters, unsigned l
ength, CSSPrimitiveValue::UnitType& unit, double& number) | 63 static inline bool parseSimpleLength(const CharacterType* characters, unsigned l
ength, CSSPrimitiveValue::UnitType& unit, double& number) |
62 { | 64 { |
(...skipping 592 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
655 if (RefPtrWillBeRawPtr<CSSValue> color = parseColorValue(propertyID, string,
parserMode)) | 657 if (RefPtrWillBeRawPtr<CSSValue> color = parseColorValue(propertyID, string,
parserMode)) |
656 return color.release(); | 658 return color.release(); |
657 if (RefPtrWillBeRawPtr<CSSValue> keyword = parseKeywordValue(propertyID, str
ing)) | 659 if (RefPtrWillBeRawPtr<CSSValue> keyword = parseKeywordValue(propertyID, str
ing)) |
658 return keyword.release(); | 660 return keyword.release(); |
659 if (RefPtrWillBeRawPtr<CSSValue> transform = parseSimpleTransform(propertyID
, string)) | 661 if (RefPtrWillBeRawPtr<CSSValue> transform = parseSimpleTransform(propertyID
, string)) |
660 return transform.release(); | 662 return transform.release(); |
661 return nullptr; | 663 return nullptr; |
662 } | 664 } |
663 | 665 |
664 } // namespace blink | 666 } // namespace blink |
OLD | NEW |