Index: third_party/WebKit/Source/core/animation/ShadowInterpolationFunctions.cpp |
diff --git a/third_party/WebKit/Source/core/animation/ShadowInterpolationFunctions.cpp b/third_party/WebKit/Source/core/animation/ShadowInterpolationFunctions.cpp |
index cf7c77215c0b069d93fbe1624d3dfbe3d48d857c..697f1bda280b674c9dd4786366b454fa62339ada 100644 |
--- a/third_party/WebKit/Source/core/animation/ShadowInterpolationFunctions.cpp |
+++ b/third_party/WebKit/Source/core/animation/ShadowInterpolationFunctions.cpp |
@@ -12,7 +12,6 @@ |
#include "core/css/resolver/StyleResolverState.h" |
#include "core/style/ShadowData.h" |
#include "platform/geometry/FloatPoint.h" |
-#include <memory> |
namespace blink { |
@@ -63,7 +62,7 @@ PairwiseInterpolationValue ShadowInterpolationFunctions::maybeMergeSingles(Inter |
InterpolationValue ShadowInterpolationFunctions::convertShadowData(const ShadowData& shadowData, double zoom) |
{ |
- std::unique_ptr<InterpolableList> interpolableList = InterpolableList::create(ShadowComponentIndexCount); |
+ OwnPtr<InterpolableList> interpolableList = InterpolableList::create(ShadowComponentIndexCount); |
interpolableList->set(ShadowX, CSSLengthInterpolationType::createInterpolablePixels(shadowData.x() / zoom)); |
interpolableList->set(ShadowY, CSSLengthInterpolationType::createInterpolablePixels(shadowData.y() / zoom)); |
interpolableList->set(ShadowBlur, CSSLengthInterpolationType::createInterpolablePixels(shadowData.blur() / zoom)); |
@@ -86,7 +85,7 @@ InterpolationValue ShadowInterpolationFunctions::maybeConvertCSSValue(const CSSV |
return nullptr; |
} |
- std::unique_ptr<InterpolableList> interpolableList = InterpolableList::create(ShadowComponentIndexCount); |
+ OwnPtr<InterpolableList> interpolableList = InterpolableList::create(ShadowComponentIndexCount); |
static_assert(ShadowX == 0, "Enum ordering check."); |
static_assert(ShadowY == 1, "Enum ordering check."); |
static_assert(ShadowBlur == 2, "Enum ordering check."); |
@@ -110,7 +109,7 @@ InterpolationValue ShadowInterpolationFunctions::maybeConvertCSSValue(const CSSV |
} |
if (shadow.color) { |
- std::unique_ptr<InterpolableValue> interpolableColor = CSSColorInterpolationType::maybeCreateInterpolableColor(*shadow.color); |
+ OwnPtr<InterpolableValue> interpolableColor = CSSColorInterpolationType::maybeCreateInterpolableColor(*shadow.color); |
if (!interpolableColor) |
return nullptr; |
interpolableList->set(ShadowColor, std::move(interpolableColor)); |
@@ -121,12 +120,12 @@ InterpolationValue ShadowInterpolationFunctions::maybeConvertCSSValue(const CSSV |
return InterpolationValue(std::move(interpolableList), ShadowNonInterpolableValue::create(style)); |
} |
-std::unique_ptr<InterpolableValue> ShadowInterpolationFunctions::createNeutralInterpolableValue() |
+PassOwnPtr<InterpolableValue> ShadowInterpolationFunctions::createNeutralInterpolableValue() |
{ |
return convertShadowData(ShadowData(FloatPoint(0, 0), 0, 0, Normal, StyleColor(Color::transparent)), 1).interpolableValue; |
} |
-void ShadowInterpolationFunctions::composite(std::unique_ptr<InterpolableValue>& underlyingInterpolableValue, RefPtr<NonInterpolableValue>& underlyingNonInterpolableValue, double underlyingFraction, const InterpolableValue& interpolableValue, const NonInterpolableValue* nonInterpolableValue) |
+void ShadowInterpolationFunctions::composite(OwnPtr<InterpolableValue>& underlyingInterpolableValue, RefPtr<NonInterpolableValue>& underlyingNonInterpolableValue, double underlyingFraction, const InterpolableValue& interpolableValue, const NonInterpolableValue* nonInterpolableValue) |
{ |
ASSERT(nonInterpolableValuesAreCompatible(underlyingNonInterpolableValue.get(), nonInterpolableValue)); |
InterpolableList& underlyingInterpolableList = toInterpolableList(*underlyingInterpolableValue); |