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

Unified Diff: third_party/WebKit/Source/core/animation/AnimationEffectTiming.cpp

Issue 1851003002: Throw TypeError if easing string is invalid. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix "liner"->"linear" typo in ui/file_manager js file Created 4 years, 8 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/AnimationEffectTiming.cpp
diff --git a/third_party/WebKit/Source/core/animation/AnimationEffectTiming.cpp b/third_party/WebKit/Source/core/animation/AnimationEffectTiming.cpp
index 8d784c02166b61daee1bd57a6e72cdfc9585ee34..9135e0cbe4784c9c62758ce4ef01b42fe8b127e1 100644
--- a/third_party/WebKit/Source/core/animation/AnimationEffectTiming.cpp
+++ b/third_party/WebKit/Source/core/animation/AnimationEffectTiming.cpp
@@ -4,6 +4,7 @@
#include "core/animation/AnimationEffectTiming.h"
+#include "bindings/core/v8/ExceptionState.h"
#include "bindings/core/v8/UnionTypesCore.h"
#include "core/animation/AnimationEffect.h"
#include "core/animation/KeyframeEffect.h"
@@ -127,7 +128,7 @@ void AnimationEffectTiming::setDirection(String direction)
m_parent->updateSpecifiedTiming(timing);
}
-void AnimationEffectTiming::setEasing(String easing)
+void AnimationEffectTiming::setEasing(String easing, ExceptionState& exceptionState)
{
Timing timing = m_parent->specifiedTiming();
// The AnimationEffectTiming might not be attached to a document at this
@@ -135,8 +136,8 @@ void AnimationEffectTiming::setEasing(String easing)
// calls are not considered in the WebAnimationsEasingAsFunction*
// UseCounters, but the bug we are tracking there does not come through
// this interface.
- TimingInput::setTimingFunction(timing, easing, nullptr);
- m_parent->updateSpecifiedTiming(timing);
+ if (TimingInput::setTimingFunction(timing, easing, nullptr, exceptionState))
+ m_parent->updateSpecifiedTiming(timing);
}
DEFINE_TRACE(AnimationEffectTiming)

Powered by Google App Engine
This is Rietveld 408576698