mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-14 04:03:47 +00:00
Bug 1263235, part 2 - Make PContent::AsyncMessage and PContentBridge::AsyncMessage's data argument last. r=smaug
This commit is contained in:
parent
33947a1b40
commit
8fc2a0583c
@ -2029,8 +2029,8 @@ public:
|
||||
if (aCpows && !cc->GetCPOWManager()->Wrap(aCx, aCpows, &cpows)) {
|
||||
return NS_ERROR_UNEXPECTED;
|
||||
}
|
||||
if (!cc->SendAsyncMessage(PromiseFlatString(aMessage), data, cpows,
|
||||
IPC::Principal(aPrincipal))) {
|
||||
if (!cc->SendAsyncMessage(PromiseFlatString(aMessage), cpows,
|
||||
IPC::Principal(aPrincipal), data)) {
|
||||
return NS_ERROR_UNEXPECTED;
|
||||
}
|
||||
|
||||
|
@ -60,11 +60,11 @@ ContentBridgeChild::DeferredDestroy()
|
||||
|
||||
bool
|
||||
ContentBridgeChild::RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData,
|
||||
InfallibleTArray<jsipc::CpowEntry>&& aCpows,
|
||||
const IPC::Principal& aPrincipal)
|
||||
const IPC::Principal& aPrincipal,
|
||||
const ClonedMessageData& aData)
|
||||
{
|
||||
return nsIContentChild::RecvAsyncMessage(aMsg, aData, Move(aCpows), aPrincipal);
|
||||
return nsIContentChild::RecvAsyncMessage(aMsg, Move(aCpows), aPrincipal, aData);
|
||||
}
|
||||
|
||||
PBlobChild*
|
||||
|
@ -28,9 +28,9 @@ public:
|
||||
void DeferredDestroy();
|
||||
|
||||
virtual bool RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData,
|
||||
InfallibleTArray<jsipc::CpowEntry>&& aCpows,
|
||||
const IPC::Principal& aPrincipal) override;
|
||||
const IPC::Principal& aPrincipal,
|
||||
const ClonedMessageData& aData) override;
|
||||
|
||||
virtual PBlobChild*
|
||||
SendPBlobConstructor(PBlobChild* actor,
|
||||
|
@ -84,12 +84,12 @@ ContentBridgeParent::RecvSyncMessage(const nsString& aMsg,
|
||||
|
||||
bool
|
||||
ContentBridgeParent::RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData,
|
||||
InfallibleTArray<jsipc::CpowEntry>&& aCpows,
|
||||
const IPC::Principal& aPrincipal)
|
||||
const IPC::Principal& aPrincipal,
|
||||
const ClonedMessageData& aData)
|
||||
{
|
||||
return nsIContentParent::RecvAsyncMessage(aMsg, aData, Move(aCpows),
|
||||
aPrincipal);
|
||||
return nsIContentParent::RecvAsyncMessage(aMsg, Move(aCpows),
|
||||
aPrincipal, aData);
|
||||
}
|
||||
|
||||
PBlobParent*
|
||||
|
@ -88,9 +88,9 @@ protected:
|
||||
nsTArray<StructuredCloneData>* aRetvals) override;
|
||||
|
||||
virtual bool RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData,
|
||||
InfallibleTArray<jsipc::CpowEntry>&& aCpows,
|
||||
const IPC::Principal& aPrincipal) override;
|
||||
const IPC::Principal& aPrincipal,
|
||||
const ClonedMessageData& aData) override;
|
||||
|
||||
virtual jsipc::PJavaScriptParent* AllocPJavaScriptParent() override;
|
||||
|
||||
|
@ -2441,9 +2441,9 @@ ContentChild::RecvLoadProcessScript(const nsString& aURL)
|
||||
|
||||
bool
|
||||
ContentChild::RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData,
|
||||
InfallibleTArray<CpowEntry>&& aCpows,
|
||||
const IPC::Principal& aPrincipal)
|
||||
const IPC::Principal& aPrincipal,
|
||||
const ClonedMessageData& aData)
|
||||
{
|
||||
RefPtr<nsFrameMessageManager> cpm =
|
||||
nsFrameMessageManager::GetChildProcessManager();
|
||||
|
@ -429,9 +429,9 @@ public:
|
||||
virtual bool RecvLoadProcessScript(const nsString& aURL) override;
|
||||
|
||||
virtual bool RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData,
|
||||
InfallibleTArray<CpowEntry>&& aCpows,
|
||||
const IPC::Principal& aPrincipal) override;
|
||||
const IPC::Principal& aPrincipal,
|
||||
const ClonedMessageData& aData) override;
|
||||
|
||||
virtual bool RecvGeolocationUpdate(const GeoPosition& somewhere) override;
|
||||
|
||||
|
@ -4429,12 +4429,12 @@ ContentParent::RecvRpcMessage(const nsString& aMsg,
|
||||
|
||||
bool
|
||||
ContentParent::RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData,
|
||||
InfallibleTArray<CpowEntry>&& aCpows,
|
||||
const IPC::Principal& aPrincipal)
|
||||
const IPC::Principal& aPrincipal,
|
||||
const ClonedMessageData& aData)
|
||||
{
|
||||
return nsIContentParent::RecvAsyncMessage(aMsg, aData, Move(aCpows),
|
||||
aPrincipal);
|
||||
return nsIContentParent::RecvAsyncMessage(aMsg, Move(aCpows), aPrincipal,
|
||||
aData);
|
||||
}
|
||||
|
||||
bool
|
||||
@ -4678,7 +4678,7 @@ ContentParent::DoSendAsyncMessage(JSContext* aCx,
|
||||
// Nuwa won't receive frame messages after it is frozen.
|
||||
return NS_OK;
|
||||
}
|
||||
if (!SendAsyncMessage(nsString(aMessage), data, cpows, Principal(aPrincipal))) {
|
||||
if (!SendAsyncMessage(nsString(aMessage), cpows, Principal(aPrincipal), data)) {
|
||||
return NS_ERROR_UNEXPECTED;
|
||||
}
|
||||
return NS_OK;
|
||||
|
@ -946,9 +946,9 @@ private:
|
||||
nsTArray<StructuredCloneData>* aRetvals) override;
|
||||
|
||||
virtual bool RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData,
|
||||
InfallibleTArray<CpowEntry>&& aCpows,
|
||||
const IPC::Principal& aPrincipal) override;
|
||||
const IPC::Principal& aPrincipal,
|
||||
const ClonedMessageData& aData) override;
|
||||
|
||||
virtual bool RecvFilePathUpdateNotify(const nsString& aType,
|
||||
const nsString& aStorageName,
|
||||
|
@ -1216,8 +1216,8 @@ parent:
|
||||
async NotifyBenchmarkResult(nsString aCodecName, uint32_t aDecodeFPS);
|
||||
|
||||
both:
|
||||
async AsyncMessage(nsString aMessage, ClonedMessageData aData,
|
||||
CpowEntry[] aCpows, Principal aPrincipal);
|
||||
async AsyncMessage(nsString aMessage, CpowEntry[] aCpows,
|
||||
Principal aPrincipal, ClonedMessageData aData);
|
||||
};
|
||||
|
||||
}
|
||||
|
@ -51,8 +51,8 @@ both:
|
||||
|
||||
async PBlob(BlobConstructorParams params);
|
||||
|
||||
async AsyncMessage(nsString aMessage, ClonedMessageData aData,
|
||||
CpowEntry[] aCpows, Principal aPrincipal);
|
||||
async AsyncMessage(nsString aMessage, CpowEntry[] aCpows,
|
||||
Principal aPrincipal, ClonedMessageData aData);
|
||||
};
|
||||
|
||||
}
|
||||
|
@ -111,9 +111,9 @@ nsIContentChild::GetOrCreateActorForBlobImpl(BlobImpl* aImpl)
|
||||
|
||||
bool
|
||||
nsIContentChild::RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData,
|
||||
InfallibleTArray<CpowEntry>&& aCpows,
|
||||
const IPC::Principal& aPrincipal)
|
||||
const IPC::Principal& aPrincipal,
|
||||
const ClonedMessageData& aData)
|
||||
{
|
||||
RefPtr<nsFrameMessageManager> cpm = nsFrameMessageManager::GetChildProcessManager();
|
||||
if (cpm) {
|
||||
|
@ -80,9 +80,9 @@ protected:
|
||||
virtual bool DeallocPBlobChild(PBlobChild* aActor);
|
||||
|
||||
virtual bool RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData,
|
||||
InfallibleTArray<jsipc::CpowEntry>&& aCpows,
|
||||
const IPC::Principal& aPrincipal);
|
||||
const IPC::Principal& aPrincipal,
|
||||
const ClonedMessageData& aData);
|
||||
};
|
||||
|
||||
NS_DEFINE_STATIC_IID_ACCESSOR(nsIContentChild, NS_ICONTENTCHILD_IID)
|
||||
|
@ -269,9 +269,9 @@ nsIContentParent::RecvRpcMessage(const nsString& aMsg,
|
||||
|
||||
bool
|
||||
nsIContentParent::RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData,
|
||||
InfallibleTArray<CpowEntry>&& aCpows,
|
||||
const IPC::Principal& aPrincipal)
|
||||
const IPC::Principal& aPrincipal,
|
||||
const ClonedMessageData& aData)
|
||||
{
|
||||
// FIXME Permission check in Content process
|
||||
nsIPrincipal* principal = aPrincipal;
|
||||
|
@ -110,9 +110,9 @@ protected: // IPDL methods
|
||||
const IPC::Principal& aPrincipal,
|
||||
nsTArray<ipc::StructuredCloneData>* aRetvals);
|
||||
virtual bool RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData,
|
||||
InfallibleTArray<jsipc::CpowEntry>&& aCpows,
|
||||
const IPC::Principal& aPrincipal);
|
||||
const IPC::Principal& aPrincipal,
|
||||
const ClonedMessageData& aData);
|
||||
|
||||
protected: // members
|
||||
RefPtr<nsFrameMessageManager> mMessageManager;
|
||||
|
Loading…
x
Reference in New Issue
Block a user