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

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

Issue 8351052: Created a DownloadManager interface, for use in unit tests.. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merged with trunk Created 9 years, 1 month 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/download/download_service.cc ('k') | content/browser/download/download_manager.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/downloads_dom_handler.cc
diff --git a/chrome/browser/ui/webui/downloads_dom_handler.cc b/chrome/browser/ui/webui/downloads_dom_handler.cc
index f707ce2a1042a7351bbbdc142548aa98b4515753..fb6c08a5550d0391bb6ac434e9d1a556683a4441 100644
--- a/chrome/browser/ui/webui/downloads_dom_handler.cc
+++ b/chrome/browser/ui/webui/downloads_dom_handler.cc
@@ -124,7 +124,7 @@ DownloadsDOMHandler::DownloadsDOMHandler(DownloadManager* dlm)
download_manager_(dlm),
callback_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) {
// Create our fileicon data source.
- Profile::FromBrowserContext(dlm->browser_context())->
+ Profile::FromBrowserContext(dlm->BrowserContext())->
GetChromeURLDataManager()->AddDataSource(
#if defined(OS_CHROMEOS)
new FileIconSourceCros());
@@ -144,7 +144,7 @@ void DownloadsDOMHandler::Init() {
download_manager_->AddObserver(this);
Profile* profile =
- Profile::FromBrowserContext(download_manager_->browser_context());
+ Profile::FromBrowserContext(download_manager_->BrowserContext());
Profile* original_profile = profile->GetOriginalProfile();
if (original_profile != profile) {
original_download_manager_observer_.reset(
@@ -225,7 +225,7 @@ void DownloadsDOMHandler::ModelChanged() {
&download_items_);
// If we have a parent profile, let it add its downloads to the results.
Profile* profile =
- Profile::FromBrowserContext(download_manager_->browser_context());
+ Profile::FromBrowserContext(download_manager_->BrowserContext());
if (profile->GetOriginalProfile() != profile) {
DownloadServiceFactory::GetForProfile(
profile->GetOriginalProfile())->GetDownloadManager()->SearchDownloads(
@@ -346,7 +346,7 @@ void DownloadsDOMHandler::HandleClearAll(const ListValue* args) {
download_manager_->RemoveAllDownloads();
Profile* profile =
- Profile::FromBrowserContext(download_manager_->browser_context());
+ Profile::FromBrowserContext(download_manager_->BrowserContext());
// If this is an incognito downloader, clear All should clear main download
// manager as well.
if (profile->GetOriginalProfile() != profile)
« no previous file with comments | « chrome/browser/download/download_service.cc ('k') | content/browser/download/download_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698