Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(103)

Unified Diff: content/app/content_main_runner.cc

Issue 1984123003: Create ContentGpuClient for kInProcessGPU (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/app/content_main_runner.cc
diff --git a/content/app/content_main_runner.cc b/content/app/content_main_runner.cc
index 404362b3b199a451219a82bff4d92529e6cceff2..95b852619e5c5bb8c793575a63a7080d8e0315c1 100644
--- a/content/app/content_main_runner.cc
+++ b/content/app/content_main_runner.cc
@@ -262,9 +262,10 @@ class ContentClientInitializer {
#endif // !CHROME_MULTIPLE_DLL_CHILD
#if !defined(CHROME_MULTIPLE_DLL_BROWSER)
+ base::CommandLine* cmd = base::CommandLine::ForCurrentProcess();
if (process_type == switches::kGpuProcess ||
- base::CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kSingleProcess)) {
+ cmd->HasSwitch(switches::kSingleProcess) ||
+ (process_type.empty() && cmd->HasSwitch(switches::kInProcessGPU))) {
if (delegate)
content_client->gpu_ = delegate->CreateContentGpuClient();
if (!content_client->gpu_)
@@ -272,8 +273,7 @@ class ContentClientInitializer {
}
if (process_type == switches::kRendererProcess ||
- base::CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kSingleProcess)) {
+ cmd->HasSwitch(switches::kSingleProcess)) {
if (delegate)
content_client->renderer_ = delegate->CreateContentRendererClient();
if (!content_client->renderer_)
@@ -281,8 +281,7 @@ class ContentClientInitializer {
}
if (process_type == switches::kUtilityProcess ||
- base::CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kSingleProcess)) {
+ cmd->HasSwitch(switches::kSingleProcess)) {
if (delegate)
content_client->utility_ = delegate->CreateContentUtilityClient();
// TODO(scottmg): http://crbug.com/237249 Should be in _child.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698