namespace content {
+#if !defined(CHROME_MULTIPLE_DLL_CHILD)
base::LazyInstance<ContentBrowserClient>
g_empty_content_browser_client = LAZY_INSTANCE_INITIALIZER;
+#endif // !CHROME_MULTIPLE_DLL_CHILD
+
#if !defined(OS_IOS) && !defined(CHROME_MULTIPLE_DLL_BROWSER)
base::LazyInstance<ContentPluginClient>
g_empty_content_plugin_client = LAZY_INSTANCE_INITIALIZER;
static void Set(const std::string& process_type,
ContentMainDelegate* delegate) {
ContentClient* content_client = GetContentClient();
+#if !defined(CHROME_MULTIPLE_DLL_CHILD)
if (process_type.empty()) {
if (delegate)
content_client->browser_ = delegate->CreateContentBrowserClient();
if (!content_client->browser_)
content_client->browser_ = &g_empty_content_browser_client.Get();
}
+#endif // !CHROME_MULTIPLE_DLL_CHILD
#if !defined(OS_IOS) && !defined(CHROME_MULTIPLE_DLL_BROWSER)
if (process_type == switches::kPluginProcess ||
#if !defined(OS_IOS)
static void RegisterMainThreadFactories() {
-#if !defined(CHROME_MULTIPLE_DLL_BROWSER)
+#if !defined(CHROME_MULTIPLE_DLL_BROWSER) && !defined(CHROME_MULTIPLE_DLL_CHILD)
UtilityProcessHostImpl::RegisterUtilityMainThreadFactory(
CreateInProcessUtilityThread);
RenderProcessHostImpl::RegisterRendererMainThreadFactory(
LOG(FATAL) <<
"--in-process-gpu is not supported in chrome multiple dll browser.";
}
-#endif
+#endif // !CHROME_MULTIPLE_DLL_BROWSER && !CHROME_MULTIPLE_DLL_CHILD
}
// Run the FooMain() for a given process type.
InitializeMojo();
#endif
+#if defined(OS_WIN)
+ bool init_device_scale_factor = true;
+ if (command_line.HasSwitch(switches::kDeviceScaleFactor)) {
+ std::string scale_factor_string = command_line.GetSwitchValueASCII(
+ switches::kDeviceScaleFactor);
+ double scale_factor = 0;
+ if (base::StringToDouble(scale_factor_string, &scale_factor)) {
+ init_device_scale_factor = false;
+ gfx::InitDeviceScaleFactor(scale_factor);
+ }
+ }
+ if (init_device_scale_factor)
+ ui::win::InitDeviceScaleFactor();
+#endif
+
if (!GetContentClient())
SetContentClient(&empty_content_client_);
ContentClientInitializer::Set(process_type, delegate_);
MachBroker::ChildSendTaskPortToParent();
}
#elif defined(OS_WIN)
- base::TimeTicks::SetNowIsHighResNowIfSupported();
-
- bool init_device_scale_factor = true;
- if (command_line.HasSwitch(switches::kDeviceScaleFactor)) {
- std::string scale_factor_string = command_line.GetSwitchValueASCII(
- switches::kDeviceScaleFactor);
- double scale_factor = 0;
- if (base::StringToDouble(scale_factor_string, &scale_factor)) {
- init_device_scale_factor = false;
- gfx::InitDeviceScaleFactor(scale_factor);
- }
- }
- if (init_device_scale_factor)
- ui::win::InitDeviceScaleFactor();
-
SetupCRT(command_line);
#endif