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

Unified Diff: chrome/browser/ui/cocoa/download/download_item_mac.mm

Issue 15011006: Remove DownloadItem::GetUserVerifiedFilePath() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge with r201294 Created 7 years, 7 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/cocoa/download/download_item_mac.mm
diff --git a/chrome/browser/ui/cocoa/download/download_item_mac.mm b/chrome/browser/ui/cocoa/download/download_item_mac.mm
index a8c4872062051c58e25c84311d64fdd10f191636..3efffe17d004d0b8b376dcdb01c28f49cf316117 100644
--- a/chrome/browser/ui/cocoa/download/download_item_mac.mm
+++ b/chrome/browser/ui/cocoa/download/download_item_mac.mm
@@ -35,12 +35,9 @@ void DownloadItemMac::OnDownloadUpdated(content::DownloadItem* download) {
[item_controller_ clearDangerousMode];
}
- if (download->GetUserVerifiedFilePath() != lastFilePath_) {
- // Turns out the file path is "Unconfirmed %d.crdownload" for dangerous
- // downloads. When the download is confirmed, the file is renamed on
- // another thread, so reload the icon if the download filename changes.
+ if (download->GetTargetFilePath() != lastFilePath_) {
LoadIcon();
- lastFilePath_ = download->GetUserVerifiedFilePath();
+ lastFilePath_ = download->GetTargetFilePath();
[item_controller_ updateToolTip];
}
@@ -82,7 +79,7 @@ void DownloadItemMac::LoadIcon() {
}
// We may already have this particular image cached.
- base::FilePath file = download_model_.download()->GetUserVerifiedFilePath();
+ base::FilePath file = download_model_.download()->GetTargetFilePath();
gfx::Image* icon = icon_manager->LookupIconFromFilepath(
file, IconLoader::ALL);
if (icon) {
« no previous file with comments | « chrome/browser/extensions/api/downloads/downloads_api.cc ('k') | chrome/browser/ui/gtk/download/download_item_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698