| 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 // The DownloadManager object manages the process of downloading, including | 5 // The DownloadManager object manages the process of downloading, including |
| 6 // updates to the history system and providing the information for displaying | 6 // updates to the history system and providing the information for displaying |
| 7 // the downloads view in the Destinations tab. There is one DownloadManager per | 7 // the downloads view in the Destinations tab. There is one DownloadManager per |
| 8 // active browser context in Chrome. | 8 // active browser context in Chrome. |
| 9 // | 9 // |
| 10 // Download observers: | 10 // Download observers: |
| (...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 219 virtual DownloadItem* CreateSavePackageDownloadItem( | 219 virtual DownloadItem* CreateSavePackageDownloadItem( |
| 220 const FilePath& main_file_path, | 220 const FilePath& main_file_path, |
| 221 const GURL& page_url, | 221 const GURL& page_url, |
| 222 bool is_otr, | 222 bool is_otr, |
| 223 DownloadItem::Observer* observer) = 0; | 223 DownloadItem::Observer* observer) = 0; |
| 224 | 224 |
| 225 // Clears the last download path, used to initialize "save as" dialogs. | 225 // Clears the last download path, used to initialize "save as" dialogs. |
| 226 virtual void ClearLastDownloadPath() = 0; | 226 virtual void ClearLastDownloadPath() = 0; |
| 227 | 227 |
| 228 // Called by the delegate after the save as dialog is closed. | 228 // Called by the delegate after the save as dialog is closed. |
| 229 virtual void FileSelected(const FilePath& path, void* params) = 0; | 229 virtual void FileSelected(const FilePath& path, int32 download_id) = 0; |
| 230 virtual void FileSelectionCanceled(void* params) = 0; | 230 virtual void FileSelectionCanceled(int32 download_id) = 0; |
| 231 | 231 |
| 232 // Called by the delegate if it delayed the download in | 232 // Called by the delegate if it delayed the download in |
| 233 // DownloadManagerDelegate::ShouldStartDownload and now is ready. | 233 // DownloadManagerDelegate::ShouldStartDownload and now is ready. |
| 234 virtual void RestartDownload(int32 download_id) = 0; | 234 virtual void RestartDownload(int32 download_id) = 0; |
| 235 | 235 |
| 236 // Checks whether downloaded files still exist. Updates state of downloads | 236 // Checks whether downloaded files still exist. Updates state of downloads |
| 237 // that refer to removed files. The check runs in the background and may | 237 // that refer to removed files. The check runs in the background and may |
| 238 // finish asynchronously after this method returns. | 238 // finish asynchronously after this method returns. |
| 239 virtual void CheckForHistoryFilesRemoval() = 0; | 239 virtual void CheckForHistoryFilesRemoval() = 0; |
| 240 | 240 |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 280 friend class base::RefCountedThreadSafe< | 280 friend class base::RefCountedThreadSafe< |
| 281 DownloadManager, content::BrowserThread::DeleteOnUIThread>; | 281 DownloadManager, content::BrowserThread::DeleteOnUIThread>; |
| 282 friend struct content::BrowserThread::DeleteOnThread< | 282 friend struct content::BrowserThread::DeleteOnThread< |
| 283 content::BrowserThread::UI>; | 283 content::BrowserThread::UI>; |
| 284 friend class base::DeleteHelper<DownloadManager>; | 284 friend class base::DeleteHelper<DownloadManager>; |
| 285 }; | 285 }; |
| 286 | 286 |
| 287 } // namespace content | 287 } // namespace content |
| 288 | 288 |
| 289 #endif // CONTENT_PUBLIC_BROWSER_DOWNLOAD_MANAGER_H_ | 289 #endif // CONTENT_PUBLIC_BROWSER_DOWNLOAD_MANAGER_H_ |
| OLD | NEW |