Fix invoking ContentMain.
This commit is contained in:
parent
e0f263950e
commit
d5b2a5af26
2 changed files with 13 additions and 3 deletions
|
@ -10,6 +10,9 @@
|
||||||
#if defined(OS_MACOSX)
|
#if defined(OS_MACOSX)
|
||||||
int AtomMain(int argc, const char* argv[]) {
|
int AtomMain(int argc, const char* argv[]) {
|
||||||
atom::AtomMainDelegate delegate;
|
atom::AtomMainDelegate delegate;
|
||||||
return content::ContentMain(content::ContentMainParams(&delegate));
|
content::ContentMainParams params(&delegate);
|
||||||
|
params.argc = argc;
|
||||||
|
params.argv = argv;
|
||||||
|
return content::ContentMain(params);
|
||||||
}
|
}
|
||||||
#endif // OS_MACOSX
|
#endif // OS_MACOSX
|
||||||
|
|
|
@ -98,7 +98,11 @@ int APIENTRY wWinMain(HINSTANCE instance, HINSTANCE, wchar_t* cmd, int) {
|
||||||
sandbox::SandboxInterfaceInfo sandbox_info = {0};
|
sandbox::SandboxInterfaceInfo sandbox_info = {0};
|
||||||
content::InitializeSandboxInfo(&sandbox_info);
|
content::InitializeSandboxInfo(&sandbox_info);
|
||||||
atom::AtomMainDelegate delegate;
|
atom::AtomMainDelegate delegate;
|
||||||
return content::ContentMain(content::ContentMainParams(&delegate));
|
|
||||||
|
content::ContentMainParams params(&delegate);
|
||||||
|
params.instance = instance;
|
||||||
|
params.sandbox_info = &sandbox_info;
|
||||||
|
return content::ContentMain(params);
|
||||||
}
|
}
|
||||||
|
|
||||||
#elif defined(OS_LINUX) // defined(OS_WIN)
|
#elif defined(OS_LINUX) // defined(OS_WIN)
|
||||||
|
@ -109,7 +113,10 @@ int main(int argc, const char* argv[]) {
|
||||||
return node::Start(argc, const_cast<char**>(argv));
|
return node::Start(argc, const_cast<char**>(argv));
|
||||||
|
|
||||||
atom::AtomMainDelegate delegate;
|
atom::AtomMainDelegate delegate;
|
||||||
return content::ContentMain(content::ContentMainParams(&delegate));
|
content::ContentMainParams params(&delegate);
|
||||||
|
params.argc = argc;
|
||||||
|
params.argv = argv;
|
||||||
|
return content::ContentMain(params);
|
||||||
}
|
}
|
||||||
|
|
||||||
#else // defined(OS_LINUX)
|
#else // defined(OS_LINUX)
|
||||||
|
|
Loading…
Reference in a new issue