Chromium Code Reviews| Index: Source/bindings/dart/DartCustomElementLifecycleCallbacks.h |
| diff --git a/Source/bindings/v8/V8CustomElementLifecycleCallbacks.h b/Source/bindings/dart/DartCustomElementLifecycleCallbacks.h |
| similarity index 61% |
| copy from Source/bindings/v8/V8CustomElementLifecycleCallbacks.h |
| copy to Source/bindings/dart/DartCustomElementLifecycleCallbacks.h |
| index 71313ee9cc37f7936251c712924589a2c616c6ea..386054612ba073a2ddd6ff7f9cf54fcc4a4c5a2e 100644 |
| --- a/Source/bindings/v8/V8CustomElementLifecycleCallbacks.h |
| +++ b/Source/bindings/dart/DartCustomElementLifecycleCallbacks.h |
| @@ -28,53 +28,46 @@ |
| * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| */ |
| -#ifndef V8CustomElementLifecycleCallbacks_h |
| -#define V8CustomElementLifecycleCallbacks_h |
| +#ifndef DartCustomElementLifecycleCallbacks_h |
| +#define DartCustomElementLifecycleCallbacks_h |
| -#include "bindings/v8/ActiveDOMCallback.h" |
| #include "bindings/v8/DOMWrapperWorld.h" |
| -#include "bindings/v8/ScopedPersistent.h" |
| #include "core/dom/CustomElementLifecycleCallbacks.h" |
| #include "wtf/PassOwnPtr.h" |
| #include "wtf/PassRefPtr.h" |
| -#include <v8.h> |
| + |
| +#include <dart_api.h> |
| namespace WebCore { |
| class CustomElementLifecycleCallbacks; |
| +class DartCustomElementBinding; |
| +class CustomElementDefinition; |
|
vsm
2013/09/19 23:12:26
nit: alpha ordering
blois
2013/09/20 00:10:25
Done.
|
| class Element; |
| class ScriptExecutionContext; |
| -class V8PerContextData; |
| -class V8CustomElementLifecycleCallbacks : public CustomElementLifecycleCallbacks, ActiveDOMCallback { |
| +class DartCustomElementLifecycleCallbacks : public CustomElementLifecycleCallbacks { |
| public: |
| - static PassRefPtr<V8CustomElementLifecycleCallbacks> create(ScriptExecutionContext*, v8::Handle<v8::Object> prototype, v8::Handle<v8::Function> created, v8::Handle<v8::Function> enteredDocument, v8::Handle<v8::Function> leftDocument, v8::Handle<v8::Function> attributeChanged); |
| + static PassRefPtr<DartCustomElementLifecycleCallbacks> create(Dart_Isolate, ScriptExecutionContext*); |
| - virtual ~V8CustomElementLifecycleCallbacks(); |
| + virtual ~DartCustomElementLifecycleCallbacks(); |
| - bool setBinding(CustomElementDefinition* owner, PassOwnPtr<CustomElementBinding>); |
| + bool setBinding(CustomElementDefinition* owner, PassOwnPtr<DartCustomElementBinding>); |
| private: |
| - V8CustomElementLifecycleCallbacks(ScriptExecutionContext*, v8::Handle<v8::Object> prototype, v8::Handle<v8::Function> created, v8::Handle<v8::Function> enteredDocument, v8::Handle<v8::Function> leftDocument, v8::Handle<v8::Function> attributeChanged); |
| + DartCustomElementLifecycleCallbacks(Dart_Isolate, ScriptExecutionContext*); |
| virtual void created(Element*) OVERRIDE; |
| virtual void enteredDocument(Element*) OVERRIDE; |
| virtual void leftDocument(Element*) OVERRIDE; |
| virtual void attributeChanged(Element*, const AtomicString& name, const AtomicString& oldValue, const AtomicString& newValue) OVERRIDE; |
| - void call(const ScopedPersistent<v8::Function>& weakCallback, Element*); |
| - |
| - V8PerContextData* creationContextData(); |
| - |
| + ScriptExecutionContext* m_scriptExecutionContext; |
| CustomElementDefinition* m_owner; |
| + Dart_Isolate m_isolate; |
| RefPtr<DOMWrapperWorld> m_world; |
| - ScopedPersistent<v8::Object> m_prototype; |
| - ScopedPersistent<v8::Function> m_created; |
| - ScopedPersistent<v8::Function> m_enteredDocument; |
| - ScopedPersistent<v8::Function> m_leftDocument; |
| - ScopedPersistent<v8::Function> m_attributeChanged; |
| }; |
| } |
| -#endif // V8CustomElementLifecycleCallbacks_h |
| +#endif // DartCustomElementLifecycleCallbacks_h |