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

Unified Diff: chrome/browser/dom_ui/downloads_dom_handler.cc

Issue 350007: Convert chrome_url_data_manager (previously a global) into a Singleton. This (Closed)
Patch Set: Created 11 years, 2 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 | « chrome/browser/dom_ui/chrome_url_data_manager.cc ('k') | chrome/browser/dom_ui/downloads_ui.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/dom_ui/downloads_dom_handler.cc
diff --git a/chrome/browser/dom_ui/downloads_dom_handler.cc b/chrome/browser/dom_ui/downloads_dom_handler.cc
index 7b7791513727ff93d3c70a753fe8af7d788746cd..67994753c71d3567eb1a0f409f31980e9c6cca45 100644
--- a/chrome/browser/dom_ui/downloads_dom_handler.cc
+++ b/chrome/browser/dom_ui/downloads_dom_handler.cc
@@ -7,6 +7,7 @@
#include "app/l10n_util.h"
#include "base/basictypes.h"
#include "base/i18n/time_formatting.h"
+#include "base/singleton.h"
#include "base/string_piece.h"
#include "base/thread.h"
#include "base/values.h"
@@ -54,7 +55,7 @@ DownloadsDOMHandler::DownloadsDOMHandler(DownloadManager* dlm)
// Create our fileicon data source.
ChromeThread::PostTask(
ChromeThread::IO, FROM_HERE,
- NewRunnableMethod(&chrome_url_data_manager,
+ NewRunnableMethod(Singleton<ChromeURLDataManager>().get(),
&ChromeURLDataManager::AddDataSource,
new FileIconSource()));
}
« no previous file with comments | « chrome/browser/dom_ui/chrome_url_data_manager.cc ('k') | chrome/browser/dom_ui/downloads_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698