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

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

Issue 12850002: Move download filename determintion into a separate class. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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/download_test_file_activity_observer.cc
diff --git a/chrome/browser/download/download_test_file_activity_observer.cc b/chrome/browser/download/download_test_file_activity_observer.cc
index 2137409dea736177b4e7bfb4ec306df8d5eeeabc..59aa7405417c8b226efa675756325463ea1cf20a 100644
--- a/chrome/browser/download/download_test_file_activity_observer.cc
+++ b/chrome/browser/download/download_test_file_activity_observer.cc
@@ -38,14 +38,16 @@ class DownloadTestFileActivityObserver::MockDownloadManagerDelegate
protected:
- virtual void ChooseDownloadPath(content::DownloadItem* item,
- const base::FilePath& suggested_path,
- const FileSelectedCallback&
- callback) OVERRIDE {
+ virtual void PromptUserForDownloadPath(
+ content::DownloadItem* item,
+ const base::FilePath& suggested_path,
+ const DownloadTargetDeterminerDelegate::FileSelectedCallback&
+ callback) OVERRIDE {
+ base::FilePath target_path =
+ file_chooser_enabled_ ? suggested_path : base::FilePath();
file_chooser_displayed_ = true;
MessageLoop::current()->PostTask(
- FROM_HERE, base::Bind(callback, (file_chooser_enabled_ ? suggested_path
- : base::FilePath())));
+ FROM_HERE, base::Bind(callback, target_path, target_path));
}
virtual void OpenDownload(content::DownloadItem* item) OVERRIDE {}

Powered by Google App Engine
This is Rietveld 408576698