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

Unified Diff: chrome/browser/chromeos/drive/download_handler.cc

Issue 14640020: [Resumption 9/11] Handle filename determination for resumed downloads. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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/chromeos/drive/download_handler.cc
diff --git a/chrome/browser/chromeos/drive/download_handler.cc b/chrome/browser/chromeos/drive/download_handler.cc
index d8c68e6cc221818e369683bc083959ef1462a791..af6c00e2062e156d241aef2b5f13d482fe1ded2c 100644
--- a/chrome/browser/chromeos/drive/download_handler.cc
+++ b/chrome/browser/chromeos/drive/download_handler.cc
@@ -244,8 +244,13 @@ void DownloadHandler::OnDownloadUpdated(
data->set_complete();
break;
- case DownloadItem::CANCELLED:
case DownloadItem::INTERRUPTED:
+ // Interrupted downloads can be resumed. Keep the Drive user data around
+ // so that it can be used when the download resumes. The download is truly
+ // done when it's complete, is cancelled or is removed.
+ break;
Randy Smith (Not in Mondays) 2013/05/15 19:00:18 How does this work over a browser restart? I.e. i
asanka 2013/05/23 20:30:37 On a browser restart, drive downloads get deleted
+
+ case DownloadItem::CANCELLED:
download->SetUserData(&kDrivePathKey, NULL);
break;

Powered by Google App Engine
This is Rietveld 408576698