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

Unified Diff: chrome/browser/plugin_installer.cc

Issue 10912183: Remove DownloadManager::GetDownloadItem in favor of GetDownload() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 3 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/plugin_installer.cc
diff --git a/chrome/browser/plugin_installer.cc b/chrome/browser/plugin_installer.cc
index 2904c5b2ea318a1a419282adf159a7993c0e575b..3ffc97fa3faced8ba59071cf64112c09c60d405b 100644
--- a/chrome/browser/plugin_installer.cc
+++ b/chrome/browser/plugin_installer.cc
@@ -225,8 +225,11 @@ void PluginInstaller::DownloadStarted(
DownloadError(msg);
return;
}
- DownloadItem* download_item =
- dlm->GetActiveDownloadItem(download_id.local());
+ DownloadItem* download_item = dlm->GetDownload(download_id.local());
Randy Smith (Not in Mondays) 2012/09/13 18:52:44 I'd be inclined to put a DCHECK after this that we
benjhayden 2012/09/13 20:19:36 TODone, see response to below comment.
+ if (!download_item) {
+ DownloadError("Download not found");
+ return;
Randy Smith (Not in Mondays) 2012/09/13 18:52:44 Why the addition of the error return? GetDownload
benjhayden 2012/09/13 20:19:36 We saw in WebstoreInstaller where the DownloadStar
+ }
download_item->SetOpenWhenComplete(true);
download_item->AddObserver(this);
}

Powered by Google App Engine
This is Rietveld 408576698