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

Unified Diff: Source/core/animation/AnimatableDouble.h

Issue 29543005: Introduce DEFINE_ANIMATABLE_VALUE_TYPE_CASTS to replace manual toFoo() for animatable value (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 2 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: Source/core/animation/AnimatableDouble.h
diff --git a/Source/core/animation/AnimatableDouble.h b/Source/core/animation/AnimatableDouble.h
index ffd921f2c591edc5e3106dfbcafa28de8c8f24f6..b2b71165a6a0d7ac561e3ffb68eb1e83d48ff986 100644
--- a/Source/core/animation/AnimatableDouble.h
+++ b/Source/core/animation/AnimatableDouble.h
@@ -70,11 +70,7 @@ private:
Constraint m_constraint;
};
-inline const AnimatableDouble* toAnimatableDouble(const AnimatableValue* value)
-{
- ASSERT_WITH_SECURITY_IMPLICATION(value && value->isDouble());
- return static_cast<const AnimatableDouble*>(value);
-}
+DEFINE_ANIMATABLE_VALUE_TYPE_CASTS(AnimatableDouble, isDouble());
} // namespace WebCore

Powered by Google App Engine
This is Rietveld 408576698