Index: bindings/js/JSInjectedScriptHostCustom.cpp |
=================================================================== |
--- bindings/js/JSInjectedScriptHostCustom.cpp (revision 53180) |
+++ bindings/js/JSInjectedScriptHostCustom.cpp (working copy) |
@@ -47,8 +47,6 @@ |
#include "InspectorController.h" |
#include "InspectorResource.h" |
#include "JSDOMWindow.h" |
-#include "JSInspectedObjectWrapper.h" |
-#include "JSInspectorCallbackWrapper.h" |
#include "JSNode.h" |
#include "JSRange.h" |
#include "Node.h" |
@@ -112,29 +110,10 @@ |
Database* database = impl()->databaseForId(args.at(0).toInt32(exec)); |
if (!database) |
return jsUndefined(); |
- // Could use currentWorld(exec) ... but which exec! The following mixed use of exec & inspectedWindow->globalExec() scares me! |
- JSDOMWindow* inspectedWindow = toJSDOMWindow(ic->inspectedPage()->mainFrame(), debuggerWorld()); |
- return JSInspectedObjectWrapper::wrap(inspectedWindow->globalExec(), toJS(exec, database)); |
+ return toJS(exec, database); |
} |
#endif |
-JSValue JSInjectedScriptHost::inspectedWindow(ExecState*, const ArgList&) |
-{ |
- InspectorController* ic = impl()->inspectorController(); |
- if (!ic) |
- return jsUndefined(); |
- JSDOMWindow* inspectedWindow = toJSDOMWindow(ic->inspectedPage()->mainFrame(), debuggerWorld()); |
- return JSInspectedObjectWrapper::wrap(inspectedWindow->globalExec(), inspectedWindow); |
-} |
- |
-JSValue JSInjectedScriptHost::wrapCallback(ExecState* exec, const ArgList& args) |
-{ |
- if (args.size() < 1) |
- return jsUndefined(); |
- |
- return JSInspectorCallbackWrapper::wrap(exec, args.at(0)); |
-} |
- |
#if ENABLE(JAVASCRIPT_DEBUGGER) |
JSValue JSInjectedScriptHost::currentCallFrame(ExecState* exec, const ArgList&) |
@@ -143,11 +122,8 @@ |
if (!callFrame || !callFrame->isValid()) |
return jsUndefined(); |
- // FIXME: I am not sure if this is actually needed. Can we just use exec? |
- ExecState* globalExec = callFrame->scopeChain()->globalObject->globalExec(); |
- |
JSLock lock(SilenceAssertionsOnly); |
- return JSInspectedObjectWrapper::wrap(globalExec, toJS(exec, callFrame)); |
+ return toJS(exec, callFrame); |
} |
#endif |
@@ -166,36 +142,15 @@ |
return jsUndefined(); |
JSLock lock(SilenceAssertionsOnly); |
- JSDOMWindow* inspectedWindow = toJSDOMWindow(ic->inspectedPage()->mainFrame(), debuggerWorld()); |
- return JSInspectedObjectWrapper::wrap(inspectedWindow->globalExec(), toJS(exec, deprecatedGlobalObjectForPrototype(inspectedWindow->globalExec()), node)); |
+ return toJS(exec, node); |
} |
-JSValue JSInjectedScriptHost::wrapObject(ExecState* exec, const ArgList& args) |
-{ |
- if (args.size() < 2) |
- return jsUndefined(); |
- |
- return impl()->wrapObject(ScriptValue(args.at(0)), args.at(1).toString(exec)).jsValue(); |
-} |
- |
-JSValue JSInjectedScriptHost::unwrapObject(ExecState* exec, const ArgList& args) |
-{ |
- if (args.size() < 1) |
- return jsUndefined(); |
- |
- return impl()->unwrapObject(args.at(0).toString(exec)).jsValue(); |
-} |
- |
JSValue JSInjectedScriptHost::pushNodePathToFrontend(ExecState* exec, const ArgList& args) |
{ |
if (args.size() < 3) |
return jsUndefined(); |
- JSQuarantinedObjectWrapper* wrapper = JSQuarantinedObjectWrapper::asWrapper(args.at(0)); |
- if (!wrapper) |
- return jsUndefined(); |
- |
- Node* node = toNode(wrapper->unwrappedObject()); |
+ Node* node = toNode(args.at(0)); |
if (!node) |
return jsUndefined(); |
@@ -210,11 +165,7 @@ |
if (args.size() < 1) |
return jsUndefined(); |
- JSQuarantinedObjectWrapper* wrapper = JSQuarantinedObjectWrapper::asWrapper(args.at(0)); |
- if (!wrapper) |
- return jsUndefined(); |
- |
- Database* database = toDatabase(wrapper->unwrappedObject()); |
+ Database* database = toDatabase(args.at(0)); |
if (database) |
impl()->selectDatabase(database); |
return jsUndefined(); |
@@ -230,11 +181,7 @@ |
if (!ic) |
return jsUndefined(); |
- JSQuarantinedObjectWrapper* wrapper = JSQuarantinedObjectWrapper::asWrapper(args.at(0)); |
- if (!wrapper) |
- return jsUndefined(); |
- |
- Storage* storage = toStorage(wrapper->unwrappedObject()); |
+ Storage* storage = toStorage(args.at(0)); |
if (storage) |
impl()->selectDOMStorage(storage); |
return jsUndefined(); |