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:
Haojian Wu 2015-05-11 20:14:07 +08:00
parent 30d815e28f
commit abd97a7513
5 changed files with 118 additions and 3 deletions

View file

@ -64,6 +64,12 @@ void AtomMainDelegate::PreSandboxStartup() {
std::string process_type = command_line->GetSwitchValueASCII(
switches::kProcessType);
#if defined(OS_WIN)
if (process_type == switches::kUtilityProcess) {
AtomContentUtilityClient::PreSandboxStartup();
}
#endif
// Only append arguments for browser process.
if (!process_type.empty())
return;