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

Unified Diff: chrome/browser/browser_main.cc

Issue 6713082: Move WebUIFactory to chrome/browser. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: ContentWebUIClient Created 9 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
« no previous file with comments | « no previous file | chrome/browser/browser_url_handler.cc » ('j') | content/browser/tab_contents/tab_contents.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/browser_main.cc
diff --git a/chrome/browser/browser_main.cc b/chrome/browser/browser_main.cc
index 19f4d6c7a7848605ee85ae23d0a9b70f1dd5ffba..04dddce416936ed69ef49143a1d4dbb8502b1fdb 100644
--- a/chrome/browser/browser_main.cc
+++ b/chrome/browser/browser_main.cc
@@ -74,6 +74,7 @@
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/browser_init.h"
#include "chrome/browser/ui/webui/chrome_url_data_manager_backend.h"
+#include "chrome/browser/ui/webui/web_ui_factory.h"
#include "chrome/common/chrome_constants.h"
#include "chrome/common/chrome_paths.h"
#include "chrome/common/chrome_switches.h"
@@ -1457,11 +1458,14 @@ int BrowserMain(const MainFunctionParams& parameters) {
PrefService* user_prefs = profile->GetPrefs();
DCHECK(user_prefs);
- // Override the default ContentBrowserClient to let Chrome participate in
+ // Override the default ContentBrowserClient and to let Chrome participate in
// content logic. Must be done before any tabs are created.
chrome::ChromeContentBrowserClient browser_client;
content::GetContentClient()->set_browser(&browser_client);
+ // Do the same for the ContentWebUIClient.
+ content::GetContentClient()->set_web_ui(WebUIFactory::GetInstance());
+
// Tests should be able to tune login manager before showing it.
// Thus only show login manager in normal (non-testing) mode.
if (!parameters.ui_task) {
« no previous file with comments | « no previous file | chrome/browser/browser_url_handler.cc » ('j') | content/browser/tab_contents/tab_contents.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698