gecko-dev/widget/windows/PDFiumProcessChild.h
cku 07e7f9f727 Bug 1399787 - Part 9. Sandbox the PDFium process. r=bobowen,jwatt
MozReview-Commit-ID: 6ED7EPZvOMR

--HG--
extra : rebase_source : d8ddd2bb3551cf25c0f18151c4340e1f48d659ca
extra : intermediate-source : d90c5064d88a6468c1209f4a78ec7631592eec98
extra : source : 91b761e38efd28a69647c38531f5418fffee8f50
2017-10-18 20:52:45 +08:00

45 lines
1.1 KiB
C++

/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef PDFIUMPROCESSCHILD_H_
#define PDFIUMPROCESSCHILD_H_
#include "mozilla/ipc/ProcessChild.h"
#include "PDFiumChild.h"
namespace mozilla {
namespace widget {
/**
* Contains the PDFiumChild object that facilitates IPC communication to/from
* the instance of the PDFium library that is run in this process.
*/
class PDFiumProcessChild final : public mozilla::ipc::ProcessChild
{
protected:
typedef mozilla::ipc::ProcessChild ProcessChild;
public:
explicit PDFiumProcessChild(ProcessId aParentPid);
~PDFiumProcessChild();
// ProcessChild functions.
bool Init(int aArgc, char* aArgv[]) override;
void CleanUp() override;
private:
DISALLOW_COPY_AND_ASSIGN(PDFiumProcessChild);
PDFiumChild mPDFiumActor;
#if defined(MOZ_SANDBOX)
PRLibrary* mPDFium;
#endif
};
} // namespace widget
} // namespace mozilla
#endif // PDFIUMPROCESSCHILD_H_