Load pdf component dynamically.
Ship pdf as dll library, electron only loads pdf.dll when calling print API. In this way, the developer who don't need print feature can safe remove the pdf.dll in saving their binary size.
This commit is contained in:
parent
30d815e28f
commit
abd97a7513
5 changed files with 118 additions and 3 deletions
|
@ -71,4 +71,9 @@ void AtomContentUtilityClient::OnStartupPing() {
|
|||
// Don't release the process, we assume further messages are on the way.
|
||||
}
|
||||
|
||||
// static
|
||||
void AtomContentUtilityClient::PreSandboxStartup() {
|
||||
PrintingHandler::PreSandboxStartup();
|
||||
}
|
||||
|
||||
} // namespace atom
|
||||
|
|
|
@ -31,6 +31,7 @@ class AtomContentUtilityClient : public content::ContentUtilityClient {
|
|||
void UtilityThreadStarted() override;
|
||||
bool OnMessageReceived(const IPC::Message& message) override;
|
||||
|
||||
static void PreSandboxStartup();
|
||||
|
||||
static void set_max_ipc_message_size_for_test(int64_t max_message_size) {
|
||||
max_ipc_message_size_ = max_message_size;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue