| Index: third_party/WebKit/Source/modules/compositorworker/AnimatorDefinition.h
|
| diff --git a/third_party/WebKit/Source/modules/compositorworker/AnimatorDefinition.h b/third_party/WebKit/Source/modules/compositorworker/AnimatorDefinition.h
|
| index b59cf65da38b71807602bb46b99ea4754f761a22..483f3b447f33ce8180390a2d532845799a4848d2 100644
|
| --- a/third_party/WebKit/Source/modules/compositorworker/AnimatorDefinition.h
|
| +++ b/third_party/WebKit/Source/modules/compositorworker/AnimatorDefinition.h
|
| @@ -5,7 +5,8 @@
|
| #ifndef AnimatorDefinition_h
|
| #define AnimatorDefinition_h
|
|
|
| -#include "platform/bindings/ScopedPersistent.h"
|
| +#include "platform/bindings/ScriptWrappable.h"
|
| +#include "platform/bindings/TraceWrapperV8Reference.h"
|
| #include "platform/heap/Handle.h"
|
| #include "v8/include/v8.h"
|
|
|
| @@ -17,23 +18,23 @@ namespace blink {
|
| // It can be used to instantiate new animators and also to call the Javascript
|
| // 'animate' callback on a given instance.
|
| class AnimatorDefinition final
|
| - : public GarbageCollectedFinalized<AnimatorDefinition> {
|
| + : public GarbageCollectedFinalized<AnimatorDefinition>,
|
| + public TraceWrapperBase {
|
| public:
|
| AnimatorDefinition(v8::Isolate*,
|
| v8::Local<v8::Function> constructor,
|
| v8::Local<v8::Function> animate);
|
| ~AnimatorDefinition();
|
| DEFINE_INLINE_TRACE() {}
|
| + DECLARE_TRACE_WRAPPERS();
|
|
|
| v8::Local<v8::Function> ConstructorLocal(v8::Isolate*);
|
|
|
| private:
|
| // This object keeps the constructor function, and animate function alive.
|
| - // It needs to be destroyed to break a reference cycle between it and the
|
| - // AnimationWorkletGlobalScope. This cycle is broken in
|
| - // |AnimationWorkletGlobalScope::Dispose()|.
|
| - ScopedPersistent<v8::Function> constructor_;
|
| - ScopedPersistent<v8::Function> animate_;
|
| + // It participates in wrapper tracing as it holds onto V8 wrappers.
|
| + TraceWrapperV8Reference<v8::Function> constructor_;
|
| + TraceWrapperV8Reference<v8::Function> animate_;
|
| };
|
|
|
| } // namespace blink
|
|
|