| Index: Source/bindings/core/v8/ScriptState.cpp
|
| diff --git a/Source/bindings/core/v8/ScriptState.cpp b/Source/bindings/core/v8/ScriptState.cpp
|
| index eed60a1f30136fd577931f5a5fea95c516a2e2a1..09d8cd3185dc35e76d9697f973b6a842d0051afc 100644
|
| --- a/Source/bindings/core/v8/ScriptState.cpp
|
| +++ b/Source/bindings/core/v8/ScriptState.cpp
|
| @@ -32,6 +32,7 @@ ScriptState::ScriptState(v8::Handle<v8::Context> context, PassRefPtr<DOMWrapperW
|
| , m_context(m_isolate, context)
|
| , m_world(world)
|
| , m_perContextData(V8PerContextData::create(context))
|
| + , m_globalObjectDetached(false)
|
| {
|
| ASSERT(m_world);
|
| m_context.setWeak(this, &weakCallback);
|
| @@ -44,6 +45,13 @@ ScriptState::~ScriptState()
|
| ASSERT(m_context.isEmpty());
|
| }
|
|
|
| +void ScriptState::detachGlobalObject()
|
| +{
|
| + ASSERT(!m_context.isEmpty());
|
| + context()->DetachGlobal();
|
| + m_globalObjectDetached = true;
|
| +}
|
| +
|
| bool ScriptState::evalEnabled() const
|
| {
|
| v8::HandleScope handleScope(m_isolate);
|
|
|