| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "modules/compositorworker/Animator.h" | 5 #include "modules/compositorworker/Animator.h" |
| 6 | 6 |
| 7 #include "modules/compositorworker/AnimatorDefinition.h" | 7 #include "modules/compositorworker/AnimatorDefinition.h" |
| 8 #include "platform/bindings/ScriptState.h" | 8 #include "platform/bindings/ScriptState.h" |
| 9 | 9 |
| 10 namespace blink { | 10 namespace blink { |
| 11 | 11 |
| 12 Animator::Animator(v8::Isolate* isolate, | 12 Animator::Animator(v8::Isolate* isolate, |
| 13 AnimatorDefinition* definition, | 13 AnimatorDefinition* definition, |
| 14 v8::Local<v8::Object> instance) | 14 v8::Local<v8::Object> instance) |
| 15 : definition_(definition), instance_(isolate, instance) {} | 15 : definition_(this, definition), instance_(isolate, this, instance) {} |
| 16 | 16 |
| 17 Animator::~Animator() {} | 17 Animator::~Animator() {} |
| 18 | 18 |
| 19 DEFINE_TRACE(Animator) { | 19 DEFINE_TRACE(Animator) { |
| 20 visitor->Trace(definition_); | 20 visitor->Trace(definition_); |
| 21 } | 21 } |
| 22 | 22 |
| 23 DEFINE_TRACE_WRAPPERS(Animator) { |
| 24 visitor->TraceWrappers(definition_); |
| 25 visitor->TraceWrappers(instance_.Cast<v8::Value>()); |
| 26 } |
| 27 |
| 23 } // namespace blink | 28 } // namespace blink |
| OLD | NEW |