Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(385)

Unified Diff: Source/bindings/v8/V8DOMWrapper.cpp

Issue 26792002: Reland: Reland: Implement new Blink IDL attribute [SetReference] (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: mark NodeFilter Dependent Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/bindings/v8/V8DOMWrapper.h ('k') | Source/bindings/v8/V8GCController.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/v8/V8DOMWrapper.cpp
diff --git a/Source/bindings/v8/V8DOMWrapper.cpp b/Source/bindings/v8/V8DOMWrapper.cpp
index a280a768a41b4f48d29f114fdd89d8d4b4ad2ca3..d30f7cd4f6444213cb061e3dd2fe1c97507609dd 100644
--- a/Source/bindings/v8/V8DOMWrapper.cpp
+++ b/Source/bindings/v8/V8DOMWrapper.cpp
@@ -42,41 +42,6 @@
namespace WebCore {
-class V8WrapperInstantiationScope {
-public:
- V8WrapperInstantiationScope(v8::Handle<v8::Object> creationContext, v8::Isolate* isolate)
- : m_didEnterContext(false)
- , m_context(v8::Context::GetCurrent())
- {
- // FIXME: Remove all empty creationContexts from caller sites.
- // If a creationContext is empty, we will end up creating a new object
- // in the context currently entered. This is wrong.
- if (creationContext.IsEmpty())
- return;
- v8::Handle<v8::Context> contextForWrapper = creationContext->CreationContext();
- // For performance, we enter the context only if the currently running context
- // is different from the context that we are about to enter.
- if (contextForWrapper == m_context)
- return;
- m_context = v8::Local<v8::Context>::New(isolate, contextForWrapper);
- m_didEnterContext = true;
- m_context->Enter();
- }
-
- ~V8WrapperInstantiationScope()
- {
- if (!m_didEnterContext)
- return;
- m_context->Exit();
- }
-
- v8::Handle<v8::Context> context() const { return m_context; }
-
-private:
- bool m_didEnterContext;
- v8::Handle<v8::Context> m_context;
-};
-
static v8::Local<v8::Object> wrapInShadowTemplate(v8::Local<v8::Object> wrapper, Node* impl, v8::Isolate* isolate)
{
// This is only for getting a unique pointer which we can pass to privateTemplate.
« no previous file with comments | « Source/bindings/v8/V8DOMWrapper.h ('k') | Source/bindings/v8/V8GCController.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698