OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/animation/PropertyInterpolationTypesMapping.h" | 5 #include "core/animation/PropertyInterpolationTypesMapping.h" |
6 | 6 |
7 #include "core/HTMLNames.h" | 7 #include "core/HTMLNames.h" |
8 #include "core/animation/CSSBasicShapeInterpolationType.h" | 8 #include "core/animation/CSSBasicShapeInterpolationType.h" |
9 #include "core/animation/CSSBorderImageLengthBoxInterpolationType.h" | 9 #include "core/animation/CSSBorderImageLengthBoxInterpolationType.h" |
10 #include "core/animation/CSSClipInterpolationType.h" | 10 #include "core/animation/CSSClipInterpolationType.h" |
(...skipping 30 matching lines...) Expand all Loading... |
41 #include "core/animation/SVGLengthInterpolationType.h" | 41 #include "core/animation/SVGLengthInterpolationType.h" |
42 #include "core/animation/SVGLengthListInterpolationType.h" | 42 #include "core/animation/SVGLengthListInterpolationType.h" |
43 #include "core/animation/SVGNumberInterpolationType.h" | 43 #include "core/animation/SVGNumberInterpolationType.h" |
44 #include "core/animation/SVGNumberListInterpolationType.h" | 44 #include "core/animation/SVGNumberListInterpolationType.h" |
45 #include "core/animation/SVGNumberOptionalNumberInterpolationType.h" | 45 #include "core/animation/SVGNumberOptionalNumberInterpolationType.h" |
46 #include "core/animation/SVGPathInterpolationType.h" | 46 #include "core/animation/SVGPathInterpolationType.h" |
47 #include "core/animation/SVGPointListInterpolationType.h" | 47 #include "core/animation/SVGPointListInterpolationType.h" |
48 #include "core/animation/SVGRectInterpolationType.h" | 48 #include "core/animation/SVGRectInterpolationType.h" |
49 #include "core/animation/SVGTransformListInterpolationType.h" | 49 #include "core/animation/SVGTransformListInterpolationType.h" |
50 #include "core/animation/SVGValueInterpolationType.h" | 50 #include "core/animation/SVGValueInterpolationType.h" |
| 51 #include "core/css/CSSPropertyMetadata.h" |
51 #include "wtf/PtrUtil.h" | 52 #include "wtf/PtrUtil.h" |
52 #include <memory> | 53 #include <memory> |
53 | 54 |
54 namespace blink { | 55 namespace blink { |
55 | 56 |
56 const InterpolationTypes& PropertyInterpolationTypesMapping::get(const PropertyH
andle& property) | 57 const InterpolationTypes& PropertyInterpolationTypesMapping::get(const PropertyH
andle& property) |
57 { | 58 { |
58 using ApplicableTypesMap = HashMap<PropertyHandle, std::unique_ptr<const Int
erpolationTypes>>; | 59 using ApplicableTypesMap = HashMap<PropertyHandle, std::unique_ptr<const Int
erpolationTypes>>; |
59 DEFINE_STATIC_LOCAL(ApplicableTypesMap, applicableTypesMap, ()); | 60 DEFINE_STATIC_LOCAL(ApplicableTypesMap, applicableTypesMap, ()); |
60 auto entry = applicableTypesMap.find(property); | 61 auto entry = applicableTypesMap.find(property); |
(...skipping 311 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
372 } | 373 } |
373 | 374 |
374 applicableTypes->append(wrapUnique(new SVGValueInterpolationType(attribu
te))); | 375 applicableTypes->append(wrapUnique(new SVGValueInterpolationType(attribu
te))); |
375 } | 376 } |
376 | 377 |
377 auto addResult = applicableTypesMap.add(property, std::move(applicableTypes)
); | 378 auto addResult = applicableTypesMap.add(property, std::move(applicableTypes)
); |
378 return *addResult.storedValue->value.get(); | 379 return *addResult.storedValue->value.get(); |
379 } | 380 } |
380 | 381 |
381 } // namespace blink | 382 } // namespace blink |
OLD | NEW |