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

Unified Diff: third_party/WebKit/Source/platform/v8_inspector/InspectorWrapper.h

Issue 1826623002: [DevTools] Move wrapCallFrames from InjectedScriptSource.js to native (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@remove-no-scopes
Patch Set: Created 4 years, 9 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
Index: third_party/WebKit/Source/platform/v8_inspector/InspectorWrapper.h
diff --git a/third_party/WebKit/Source/platform/v8_inspector/InspectorWrapper.h b/third_party/WebKit/Source/platform/v8_inspector/InspectorWrapper.h
index ab393f96b0934063ef859587d9b9bc8140ac941b..685b285a0b8596bc06264803871f1f33aa412998 100644
--- a/third_party/WebKit/Source/platform/v8_inspector/InspectorWrapper.h
+++ b/third_party/WebKit/Source/platform/v8_inspector/InspectorWrapper.h
@@ -6,7 +6,6 @@
#define InspectorWrapper_h
#include "platform/inspector_protocol/Collections.h"
-#include "wtf/PassOwnPtr.h"
#include <v8.h>
namespace blink {
@@ -44,14 +43,6 @@ public:
m_persistent.SetWeak(this, &WeakCallbackData::weakCallback, v8::WeakCallbackType::kParameter);
}
- WeakCallbackData(v8::Isolate* isolate, PassOwnPtr<T> impl, v8::Local<v8::Object> wrapper)
- : m_impl(impl.get())
- , m_implOwn(impl)
- , m_persistent(isolate, wrapper)
- {
- m_persistent.SetWeak(this, &WeakCallbackData::weakCallback, v8::WeakCallbackType::kParameter);
- }
-
T* m_impl;
OwnPtr<T> m_implOwn;
@@ -83,20 +74,6 @@ public:
return result;
}
- static v8::Local<v8::Object> wrap(v8::Local<v8::FunctionTemplate> constructorTemplate, v8::Local<v8::Context> context, PassOwnPtr<T> object)
- {
- v8::Context::Scope contextScope(context);
- v8::Local<v8::Object> result = InspectorWrapperBase::createWrapper(constructorTemplate, context);
- if (result.IsEmpty())
- return v8::Local<v8::Object>();
- v8::Isolate* isolate = context->GetIsolate();
- v8::Local<v8::External> objectReference = v8::External::New(isolate, new WeakCallbackData(isolate, object, result));
-
- v8::Local<v8::Private> privateKey = v8::Private::ForApi(isolate, v8::String::NewFromUtf8(isolate, hiddenPropertyName, v8::NewStringType::kInternalized).ToLocalChecked());
- result->SetPrivate(context, privateKey, objectReference);
- return result;
- }
-
static T* unwrap(v8::Local<v8::Context> context, v8::Local<v8::Object> object)
{
void* data = InspectorWrapperBase::unwrap(context, object, hiddenPropertyName);

Powered by Google App Engine
This is Rietveld 408576698