Bumping manifests a=b2g-bump
[gecko.git] / dom / ipc / ContentBridgeChild.h
blob5085f3f52d9dc2c2b51f666ba5a72f983a57a4db
1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set ts=2 et sw=2 tw=80: */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
5 * You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef mozilla_dom_ContentBridgeChild_h
8 #define mozilla_dom_ContentBridgeChild_h
10 #include "mozilla/dom/PContentBridgeChild.h"
11 #include "mozilla/dom/nsIContentChild.h"
13 namespace mozilla {
14 namespace dom {
16 class ContentBridgeChild MOZ_FINAL : public PContentBridgeChild
17 , public nsIContentChild
19 public:
20 explicit ContentBridgeChild(Transport* aTransport);
22 NS_DECL_ISUPPORTS
24 static ContentBridgeChild*
25 Create(Transport* aTransport, ProcessId aOtherProcess);
27 virtual void ActorDestroy(ActorDestroyReason aWhy) MOZ_OVERRIDE;
28 void DeferredDestroy();
30 virtual bool RecvAsyncMessage(const nsString& aMsg,
31 const ClonedMessageData& aData,
32 const InfallibleTArray<jsipc::CpowEntry>& aCpows,
33 const IPC::Principal& aPrincipal) MOZ_OVERRIDE;
35 virtual PBlobChild*
36 SendPBlobConstructor(PBlobChild* actor,
37 const BlobConstructorParams& params);
39 jsipc::JavaScriptChild* GetCPOWManager();
41 virtual bool SendPBrowserConstructor(PBrowserChild* aActor,
42 const IPCTabContext& aContext,
43 const uint32_t& aChromeFlags,
44 const uint64_t& aID,
45 const bool& aIsForApp,
46 const bool& aIsForBrowser) MOZ_OVERRIDE;
48 protected:
49 virtual ~ContentBridgeChild();
51 virtual PBrowserChild* AllocPBrowserChild(const IPCTabContext& aContext,
52 const uint32_t& aChromeFlags,
53 const uint64_t& aID,
54 const bool& aIsForApp,
55 const bool& aIsForBrowser) MOZ_OVERRIDE;
56 virtual bool DeallocPBrowserChild(PBrowserChild*) MOZ_OVERRIDE;
57 virtual bool RecvPBrowserConstructor(PBrowserChild* aCctor,
58 const IPCTabContext& aContext,
59 const uint32_t& aChromeFlags,
60 const uint64_t& aID,
61 const bool& aIsForApp,
62 const bool& aIsForBrowser) MOZ_OVERRIDE;
64 virtual mozilla::jsipc::PJavaScriptChild* AllocPJavaScriptChild() MOZ_OVERRIDE;
65 virtual bool DeallocPJavaScriptChild(mozilla::jsipc::PJavaScriptChild*) MOZ_OVERRIDE;
67 virtual PBlobChild* AllocPBlobChild(const BlobConstructorParams& aParams) MOZ_OVERRIDE;
68 virtual bool DeallocPBlobChild(PBlobChild*) MOZ_OVERRIDE;
70 DISALLOW_EVIL_CONSTRUCTORS(ContentBridgeChild);
72 protected: // members
73 nsRefPtr<ContentBridgeChild> mSelfRef;
74 Transport* mTransport; // owned
77 } // dom
78 } // mozilla
80 #endif // mozilla_dom_ContentBridgeChild_h