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

Unified Diff: chrome/browser/ui/webui/devtools_ui.cc

Issue 10196004: Changed ChromeURLDataManager to a ProfileKeyedService and made a Factory for it. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 years, 8 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: chrome/browser/ui/webui/devtools_ui.cc
diff --git a/chrome/browser/ui/webui/devtools_ui.cc b/chrome/browser/ui/webui/devtools_ui.cc
index 63a37d19eb6677f7f1a3f3f4f01db18c34be8ab1..72a611e16a21053e0b148f2d12d509861c55e038 100644
--- a/chrome/browser/ui/webui/devtools_ui.cc
+++ b/chrome/browser/ui/webui/devtools_ui.cc
@@ -10,7 +10,7 @@
#include "base/string_util.h"
#include "chrome/browser/net/chrome_url_request_context.h"
#include "chrome/browser/profiles/profile.h"
-#include "chrome/browser/ui/webui/chrome_url_data_manager.h"
+#include "chrome/browser/ui/webui/chrome_url_data_manager_factory.h"
#include "chrome/common/url_constants.h"
#include "content/public/browser/browser_thread.h"
#include "content/public/browser/devtools_client_host.h"
@@ -92,7 +92,8 @@ void DevToolsUI::RegisterDevToolsDataSource(Profile* profile) {
static bool registered = false;
if (!registered) {
DevToolsDataSource* data_source = new DevToolsDataSource();
- profile->GetChromeURLDataManager()->AddDataSource(data_source);
+ ChromeURLDataManagerFactory::GetForProfile(profile)->
+ AddDataSource(data_source);
registered = true;
}
}
@@ -100,7 +101,8 @@ void DevToolsUI::RegisterDevToolsDataSource(Profile* profile) {
DevToolsUI::DevToolsUI(content::WebUI* web_ui) : WebUIController(web_ui) {
DevToolsDataSource* data_source = new DevToolsDataSource();
Profile* profile = Profile::FromWebUI(web_ui);
- profile->GetChromeURLDataManager()->AddDataSource(data_source);
+ ChromeURLDataManagerFactory::GetForProfile(profile)->
+ AddDataSource(data_source);
}
void DevToolsUI::RenderViewCreated(

Powered by Google App Engine
This is Rietveld 408576698