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

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

Issue 3127008: Preliminary work on resuming downloads whose connections have expired.
Patch Set: Waiting to send download automation error message until after other downloads are canceled. Created 10 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/download/base_file.cc
diff --git a/chrome/browser/download/base_file.cc b/chrome/browser/download/base_file.cc
index 33b9372dc840b788fa8e6aa0d670253a69b397a3..a79e547c294bcdb35103d5c4451feed7ee3e3d64 100644
--- a/chrome/browser/download/base_file.cc
+++ b/chrome/browser/download/base_file.cc
@@ -47,6 +47,12 @@ bool BaseFile::Initialize() {
return false;
}
+bool BaseFile::ReOpen() {
+ DCHECK(ChromeThread::CurrentlyOn(ChromeThread::FILE));
+ bool opened = Open();
Paweł Hajdan Jr. 2010/10/01 09:03:55 I think it would be cleaner to just expose Open th
+ return opened;
+}
+
bool BaseFile::AppendDataToFile(const char* data, size_t data_len) {
DCHECK(ChromeThread::CurrentlyOn(ChromeThread::FILE));
@@ -154,6 +160,10 @@ void BaseFile::AnnotateWithSourceInformation() {
#endif
}
+bool BaseFile::MatchesUrlAndPath(const GURL& url, const FilePath& path) const {
+ return (url == source_url_) && (path == full_path_);
+}
+
bool BaseFile::Open() {
DCHECK(ChromeThread::CurrentlyOn(ChromeThread::FILE));
DCHECK(!full_path_.empty());

Powered by Google App Engine
This is Rietveld 408576698