| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_DOWNLOAD_CHROME_DOWNLOAD_MANAGER_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_DOWNLOAD_CHROME_DOWNLOAD_MANAGER_DELEGATE_H_ |
| 6 #define CHROME_BROWSER_DOWNLOAD_CHROME_DOWNLOAD_MANAGER_DELEGATE_H_ | 6 #define CHROME_BROWSER_DOWNLOAD_CHROME_DOWNLOAD_MANAGER_DELEGATE_H_ |
| 7 | 7 |
| 8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
| 9 #include "base/hash_tables.h" | 9 #include "base/hash_tables.h" |
| 10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 virtual void GetSaveDir(content::BrowserContext* browser_context, | 79 virtual void GetSaveDir(content::BrowserContext* browser_context, |
| 80 FilePath* website_save_dir, | 80 FilePath* website_save_dir, |
| 81 FilePath* download_save_dir, | 81 FilePath* download_save_dir, |
| 82 bool* skip_dir_check) OVERRIDE; | 82 bool* skip_dir_check) OVERRIDE; |
| 83 virtual void ChooseSavePath( | 83 virtual void ChooseSavePath( |
| 84 content::WebContents* web_contents, | 84 content::WebContents* web_contents, |
| 85 const FilePath& suggested_path, | 85 const FilePath& suggested_path, |
| 86 const FilePath::StringType& default_extension, | 86 const FilePath::StringType& default_extension, |
| 87 bool can_save_as_complete, | 87 bool can_save_as_complete, |
| 88 const content::SavePackagePathPickedCallback& callback) OVERRIDE; | 88 const content::SavePackagePathPickedCallback& callback) OVERRIDE; |
| 89 virtual void OpenDownload(content::DownloadItem* download) OVERRIDE; |
| 90 virtual void ShowDownloadInShell(content::DownloadItem* download) OVERRIDE; |
| 89 | 91 |
| 90 // Clears the last directory chosen by the user in response to a file chooser | 92 // Clears the last directory chosen by the user in response to a file chooser |
| 91 // prompt. Called when clearing recent history. | 93 // prompt. Called when clearing recent history. |
| 92 void ClearLastDownloadPath(); | 94 void ClearLastDownloadPath(); |
| 93 | 95 |
| 94 DownloadPrefs* download_prefs() { return download_prefs_.get(); } | 96 DownloadPrefs* download_prefs() { return download_prefs_.get(); } |
| 95 | 97 |
| 96 protected: | 98 protected: |
| 97 // So that test classes can inherit from this for override purposes. | 99 // So that test classes can inherit from this for override purposes. |
| 98 virtual ~ChromeDownloadManagerDelegate(); | 100 virtual ~ChromeDownloadManagerDelegate(); |
| (...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 245 #endif | 247 #endif |
| 246 | 248 |
| 247 // The directory most recently chosen by the user in response to a Save As | 249 // The directory most recently chosen by the user in response to a Save As |
| 248 // dialog for a regular download. | 250 // dialog for a regular download. |
| 249 FilePath last_download_path_; | 251 FilePath last_download_path_; |
| 250 | 252 |
| 251 DISALLOW_COPY_AND_ASSIGN(ChromeDownloadManagerDelegate); | 253 DISALLOW_COPY_AND_ASSIGN(ChromeDownloadManagerDelegate); |
| 252 }; | 254 }; |
| 253 | 255 |
| 254 #endif // CHROME_BROWSER_DOWNLOAD_CHROME_DOWNLOAD_MANAGER_DELEGATE_H_ | 256 #endif // CHROME_BROWSER_DOWNLOAD_CHROME_DOWNLOAD_MANAGER_DELEGATE_H_ |
| OLD | NEW |