| Index: chrome/browser/dom_ui/chrome_url_data_manager.cc
|
| ===================================================================
|
| --- chrome/browser/dom_ui/chrome_url_data_manager.cc (revision 50776)
|
| +++ chrome/browser/dom_ui/chrome_url_data_manager.cc (working copy)
|
| @@ -19,7 +19,6 @@
|
| #include "chrome/browser/appcache/view_appcache_internals_job_factory.h"
|
| #include "chrome/browser/browser_process.h"
|
| #include "chrome/browser/chrome_thread.h"
|
| -#include "chrome/browser/dom_ui/shared_resources_data_source.h"
|
| #include "chrome/browser/net/chrome_url_request_context.h"
|
| #include "chrome/browser/net/view_http_cache_job_factory.h"
|
| #include "chrome/common/chrome_paths.h"
|
| @@ -99,7 +98,13 @@
|
| chrome::kChromeUIDevToolsHost, inspector_dir);
|
| }
|
|
|
| - SharedResourcesDataSource::Register();
|
| + // Set up the chrome://resources/ source.
|
| + FilePath resources_dir;
|
| + if (PathService::Get(chrome::DIR_SHARED_RESOURCES, &resources_dir)) {
|
| + Singleton<ChromeURLDataManager>()->AddFileSource(
|
| + chrome::kChromeUIResourcesHost, resources_dir);
|
| + }
|
| +
|
| URLRequest::RegisterProtocolFactory(chrome::kChromeUIScheme,
|
| &ChromeURLDataManager::Factory);
|
| }
|
| @@ -110,6 +115,12 @@
|
| Singleton<ChromeURLDataManager>()->RemoveFileSource(
|
| chrome::kChromeUIDevToolsHost);
|
| }
|
| +
|
| + FilePath resources_dir;
|
| + if (PathService::Get(chrome::DIR_SHARED_RESOURCES, &resources_dir)) {
|
| + Singleton<ChromeURLDataManager>()->RemoveFileSource(
|
| + chrome::kChromeUIResourcesHost);
|
| + }
|
| }
|
|
|
| // static
|
|
|