Index: third_party/WebKit/Source/core/animation/Animation.cpp |
diff --git a/third_party/WebKit/Source/core/animation/Animation.cpp b/third_party/WebKit/Source/core/animation/Animation.cpp |
index 9cd519a2ba74efde365c05016741d943b2612823..9326e67f168bc0550e650f9c0b0be692004b49e1 100644 |
--- a/third_party/WebKit/Source/core/animation/Animation.cpp |
+++ b/third_party/WebKit/Source/core/animation/Animation.cpp |
@@ -35,6 +35,7 @@ |
#include "core/animation/KeyframeEffect.h" |
#include "core/dom/Document.h" |
#include "core/dom/ExceptionCode.h" |
+#include "core/dom/StyleChangeReason.h" |
#include "core/events/AnimationPlayerEvent.h" |
#include "core/frame/UseCounter.h" |
#include "core/inspector/InspectorInstrumentation.h" |
@@ -1079,6 +1080,14 @@ void Animation::disableCompositedAnimationForTesting() |
cancelAnimationOnCompositor(); |
} |
+void Animation::invalidateKeyframeEffect() |
+{ |
+ if (!m_content || !m_content->isKeyframeEffect()) |
+ return; |
+ |
+ toKeyframeEffect(m_content.get())->target()->setNeedsStyleRecalc(LocalStyleChange, StyleChangeReasonForTracing::create(StyleChangeReason::StyleSheetChange)); |
+} |
+ |
DEFINE_TRACE(Animation) |
{ |
visitor->trace(m_content); |