Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(10)

Unified Diff: third_party/WebKit/Source/core/animation/animatable/AnimatableLengthBox.cpp

Issue 1640643002: Add additive animation support for CSS property clip (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@_propertyInterpolationTypesMapping
Patch Set: Rebased Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/animation/animatable/AnimatableLengthBox.cpp
diff --git a/third_party/WebKit/Source/core/animation/animatable/AnimatableLengthBox.cpp b/third_party/WebKit/Source/core/animation/animatable/AnimatableLengthBox.cpp
index 4aa039bc7fb43b8e3489abd3e71d6c92ed9695fd..fb3145ab58df93dd265034f66a8c6897d7ef3836 100644
--- a/third_party/WebKit/Source/core/animation/animatable/AnimatableLengthBox.cpp
+++ b/third_party/WebKit/Source/core/animation/animatable/AnimatableLengthBox.cpp
@@ -42,6 +42,15 @@ PassRefPtr<AnimatableValue> AnimatableLengthBox::interpolateTo(const AnimatableV
AnimatableValue::interpolate(this->bottom(), lengthBox->bottom(), fraction));
}
+bool AnimatableLengthBox::usesDefaultInterpolationWith(const AnimatableValue* other) const
+{
+ const AnimatableLengthBox& otherBox = toAnimatableLengthBox(*other);
+ return usesDefaultInterpolation(left(), otherBox.left())
+ || usesDefaultInterpolation(right(), otherBox.right())
+ || usesDefaultInterpolation(top(), otherBox.top())
+ || usesDefaultInterpolation(bottom(), otherBox.bottom());
+}
+
bool AnimatableLengthBox::equalTo(const AnimatableValue* value) const
{
const AnimatableLengthBox* lengthBox = toAnimatableLengthBox(value);
« no previous file with comments | « third_party/WebKit/Source/core/animation/animatable/AnimatableLengthBox.h ('k') | third_party/WebKit/Source/core/core.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698