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

Unified Diff: content/shell/app/shell_main_delegate.cc

Issue 1777503003: More strict restrictions for content -> content/shell dependencies. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed unnecessary namespace-qualification. Created 4 years, 9 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
Index: content/shell/app/shell_main_delegate.cc
diff --git a/content/shell/app/shell_main_delegate.cc b/content/shell/app/shell_main_delegate.cc
index 5a4c73f0ee4f49c73696c1fb6b163e4b56ec0d36..0401ad7f3634d3031fada347d827db28dba7b7f4 100644
--- a/content/shell/app/shell_main_delegate.cc
+++ b/content/shell/app/shell_main_delegate.cc
@@ -26,7 +26,9 @@
#include "content/shell/browser/layout_test/layout_test_content_browser_client.h"
#include "content/shell/browser/shell_browser_main.h"
#include "content/shell/browser/shell_content_browser_client.h"
+#include "content/shell/common/layout_test/layout_test_content_client.h"
#include "content/shell/common/layout_test/layout_test_switches.h"
+#include "content/shell/common/shell_content_client.h"
#include "content/shell/common/shell_switches.h"
#include "content/shell/renderer/layout_test/layout_test_content_renderer_client.h"
#include "content/shell/renderer/shell_content_renderer_client.h"
@@ -211,7 +213,13 @@ bool ShellMainDelegate::BasicStartupComplete(int* exit_code) {
return true;
}
}
- SetContentClient(&content_client_);
+
+ content_client_.reset(base::CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kRunLayoutTest)
+ ? new LayoutTestContentClient
+ : new ShellContentClient);
+ SetContentClient(content_client_.get());
+
return false;
}
« no previous file with comments | « content/shell/app/shell_main_delegate.h ('k') | content/shell/common/layout_test/layout_test_content_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698