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

Unified Diff: chrome/browser/download/download_file_picker.h

Issue 2453633006: [downloads] Move platform specific code out of DownloadTargetDeterminer. (Closed)
Patch Set: . Created 3 years, 9 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_file_picker.h
diff --git a/chrome/browser/download/download_file_picker.h b/chrome/browser/download/download_file_picker.h
index 0763cf09fcd52deb95bbc7f8b852d9513dcad7a9..80fc2c44ffefa2039fae79d05539a641328873c0 100644
--- a/chrome/browser/download/download_file_picker.h
+++ b/chrome/browser/download/download_file_picker.h
@@ -7,6 +7,7 @@
#include "base/callback.h"
#include "base/macros.h"
+#include "chrome/browser/download/download_confirmation_result.h"
#include "ui/shell_dialogs/select_file_dialog.h"
namespace base {
@@ -26,20 +27,21 @@ class DownloadFilePicker : public ui::SelectFileDialog::Listener {
// selection, then this parameter will be the empty path. On Chrome OS,
// this path may contain virtual mount points if the user chose a virtual
// path (e.g. Google Drive).
- typedef base::Callback<void(const base::FilePath& virtual_path)>
- FileSelectedCallback;
+ typedef base::Callback<void(DownloadConfirmationResult,
+ const base::FilePath& virtual_path)>
+ ConfirmationCallback;
// Display a file picker dialog for |item|. The |suggested_path| will be used
// as the initial path displayed to the user. |callback| will always be
// invoked even if |item| is destroyed prior to the file picker completing.
static void ShowFilePicker(content::DownloadItem* item,
const base::FilePath& suggested_path,
- const FileSelectedCallback& callback);
+ const ConfirmationCallback& callback);
private:
DownloadFilePicker(content::DownloadItem* item,
const base::FilePath& suggested_path,
- const FileSelectedCallback& callback);
+ const ConfirmationCallback& callback);
~DownloadFilePicker() override;
// Runs |file_selected_callback_| with |virtual_path| and then deletes this
@@ -56,7 +58,7 @@ class DownloadFilePicker : public ui::SelectFileDialog::Listener {
base::FilePath suggested_path_;
// Callback invoked when a file selection is complete.
- FileSelectedCallback file_selected_callback_;
+ ConfirmationCallback file_selected_callback_;
// For managing select file dialogs.
scoped_refptr<ui::SelectFileDialog> select_file_dialog_;
« no previous file with comments | « chrome/browser/download/download_confirmation_result.h ('k') | chrome/browser/download/download_file_picker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698