| Index: Source/bindings/v8/CustomElementConstructorBuilder.cpp
|
| diff --git a/Source/bindings/v8/CustomElementConstructorBuilder.cpp b/Source/bindings/v8/CustomElementConstructorBuilder.cpp
|
| index 6e4dd4022ace29a341997bc8a903b0a0c0468971..532c4e628d0206067ddd9bb23fd92fcf3a7a0351 100644
|
| --- a/Source/bindings/v8/CustomElementConstructorBuilder.cpp
|
| +++ b/Source/bindings/v8/CustomElementConstructorBuilder.cpp
|
| @@ -144,11 +144,11 @@ bool CustomElementConstructorBuilder::findTagName(const AtomicString& customElem
|
| return false;
|
| }
|
|
|
| -PassRefPtr<CustomElementLifecycleCallbacks> CustomElementConstructorBuilder::createCallbacks(Document* document)
|
| +PassRefPtr<CustomElementLifecycleCallbacks> CustomElementConstructorBuilder::createCallbacks()
|
| {
|
| ASSERT(!m_prototype.IsEmpty());
|
|
|
| - RefPtr<Document> protect(document);
|
| + RefPtr<ScriptExecutionContext> scriptExecutionContext = toScriptExecutionContext(m_context);
|
|
|
| v8::TryCatch exceptionCatcher;
|
| exceptionCatcher.SetVerbose(true);
|
| @@ -159,7 +159,7 @@ PassRefPtr<CustomElementLifecycleCallbacks> CustomElementConstructorBuilder::cre
|
| v8::Handle<v8::Function> leftDocument = retrieveCallback(isolate, "leftDocumentCallback");
|
| v8::Handle<v8::Function> attributeChanged = retrieveCallback(isolate, "attributeChangedCallback");
|
|
|
| - return V8CustomElementLifecycleCallbacks::create(document, m_prototype, created, enteredDocument, leftDocument, attributeChanged);
|
| + return V8CustomElementLifecycleCallbacks::create(scriptExecutionContext.get(), m_prototype, created, enteredDocument, leftDocument, attributeChanged);
|
| }
|
|
|
| v8::Handle<v8::Function> CustomElementConstructorBuilder::retrieveCallback(v8::Isolate* isolate, const char* name)
|
|
|