Bug 1479712 part 2 - Remove unused nsIXPConnect.getWrappedNativePrototype. r=bholley

This commit is contained in:
Jan de Mooij 2018-08-02 09:15:41 +02:00
Родитель f672f4f7b6
Коммит af31466131
2 изменённых файлов: 0 добавлений и 35 удалений

Просмотреть файл

@ -328,11 +328,6 @@ interface nsIXPConnect : nsISupports
// Methods added since mozilla 0.6....
JSObjectPtr
getWrappedNativePrototype(in JSContextPtr aJSContext,
in JSObjectPtr aScope,
in nsIClassInfo aClassInfo);
jsval variantToJS(in JSContextPtr ctx, in JSObjectPtr scope, in nsIVariant value);
nsIVariant JSToVariant(in JSContextPtr ctx, in jsval value);

Просмотреть файл

@ -801,36 +801,6 @@ nsXPConnect::EvalInSandboxObject(const nsAString& source, const char* filename,
return EvalInSandbox(cx, sandbox, source, filenameStr, 1, rval);
}
NS_IMETHODIMP
nsXPConnect::GetWrappedNativePrototype(JSContext* aJSContext,
JSObject* aScopeArg,
nsIClassInfo* aClassInfo,
JSObject** aRetVal)
{
RootedObject aScope(aJSContext, aScopeArg);
JSAutoRealmAllowCCW ar(aJSContext, aScope);
XPCWrappedNativeScope* scope = ObjectScope(aScope);
if (!scope)
return UnexpectedFailure(NS_ERROR_FAILURE);
nsCOMPtr<nsIXPCScriptable> scrProto =
XPCWrappedNative::GatherProtoScriptable(aClassInfo);
AutoMarkingWrappedNativeProtoPtr proto(aJSContext);
proto = XPCWrappedNativeProto::GetNewOrUsed(scope, aClassInfo, scrProto);
if (!proto)
return UnexpectedFailure(NS_ERROR_FAILURE);
JSObject* protoObj = proto->GetJSProtoObject();
if (!protoObj)
return UnexpectedFailure(NS_ERROR_FAILURE);
*aRetVal = protoObj;
return NS_OK;
}
NS_IMETHODIMP
nsXPConnect::DebugDump(int16_t depth)
{