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

Unified Diff: chrome/browser/download/chrome_download_manager_delegate.cc

Issue 10831302: Download resumption - Preliminary (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fixed content unit tests. Created 8 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
Index: chrome/browser/download/chrome_download_manager_delegate.cc
diff --git a/chrome/browser/download/chrome_download_manager_delegate.cc b/chrome/browser/download/chrome_download_manager_delegate.cc
index 1da347f4fff4e5fb4b05ac40c092487582a3865f..da68dfec785b423c161db47c138e2063392a144a 100644
--- a/chrome/browser/download/chrome_download_manager_delegate.cc
+++ b/chrome/browser/download/chrome_download_manager_delegate.cc
@@ -251,6 +251,22 @@ FilePath ChromeDownloadManagerDelegate::GetIntermediatePath(
return dir.Append(file_name);
}
+int64 ChromeDownloadManagerDelegate::GetIntermediateFileLength(
benjhayden 2012/10/15 17:59:37 Could this move to download_utils?
+ const FilePath& path, bool temporary) {
+ // Get the intermediate file name.
+ FilePath crpath = path;
+
+ if (!temporary)
+ crpath = download_util::GetCrDownloadPath(path);
+
+ // Validate the start offset.
+ int64 end = 0;
+ if (file_util::GetFileSize(crpath, &end))
+ return end;
+
+ return 0;
+}
+
WebContents* ChromeDownloadManagerDelegate::
GetAlternativeWebContentsToNotifyForDownload() {
#if defined(OS_ANDROID)

Powered by Google App Engine
This is Rietveld 408576698