| 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 CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_DELEGATE_H_ | 5 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_DELEGATE_H_ |
| 6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_DELEGATE_H_ | 6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_DELEGATE_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include "base/callback.h" | 10 #include "base/callback.h" |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 | 62 |
| 63 // Tests if a file type should be opened automatically. | 63 // Tests if a file type should be opened automatically. |
| 64 virtual bool ShouldOpenFileBasedOnExtension(const base::FilePath& path); | 64 virtual bool ShouldOpenFileBasedOnExtension(const base::FilePath& path); |
| 65 | 65 |
| 66 // Checks whether a downloaded file still exists and updates the | 66 // Checks whether a downloaded file still exists and updates the |
| 67 // file's state if the file is already removed. | 67 // file's state if the file is already removed. |
| 68 // The check may or may not result in a later asynchronous call | 68 // The check may or may not result in a later asynchronous call |
| 69 // to OnDownloadedFileRemoved(). | 69 // to OnDownloadedFileRemoved(). |
| 70 virtual void CheckForFileRemoval(DownloadItemImpl* download_item); | 70 virtual void CheckForFileRemoval(DownloadItemImpl* download_item); |
| 71 | 71 |
| 72 // Return a GUID string used for identifying the application to the system AV |
| 73 // function for scanning downloaded files. If an empty or invalid GUID string |
| 74 // is returned, no client identification will be given to the AV function. |
| 75 virtual std::string GetApplicationClientIdForFileScanning() const; |
| 76 |
| 72 // Called when an interrupted download is resumed. | 77 // Called when an interrupted download is resumed. |
| 73 virtual void ResumeInterruptedDownload( | 78 virtual void ResumeInterruptedDownload( |
| 74 scoped_ptr<content::DownloadUrlParameters> params, | 79 scoped_ptr<content::DownloadUrlParameters> params, |
| 75 uint32_t id); | 80 uint32_t id); |
| 76 | 81 |
| 77 // For contextual issues like language and prefs. | 82 // For contextual issues like language and prefs. |
| 78 virtual BrowserContext* GetBrowserContext() const; | 83 virtual BrowserContext* GetBrowserContext() const; |
| 79 | 84 |
| 80 // Update the persistent store with our information. | 85 // Update the persistent store with our information. |
| 81 virtual void UpdatePersistence(DownloadItemImpl* download); | 86 virtual void UpdatePersistence(DownloadItemImpl* download); |
| (...skipping 14 matching lines...) Expand all Loading... |
| 96 private: | 101 private: |
| 97 // For "Outlives attached DownloadItemImpl" invariant assertion. | 102 // For "Outlives attached DownloadItemImpl" invariant assertion. |
| 98 int count_; | 103 int count_; |
| 99 | 104 |
| 100 DISALLOW_COPY_AND_ASSIGN(DownloadItemImplDelegate); | 105 DISALLOW_COPY_AND_ASSIGN(DownloadItemImplDelegate); |
| 101 }; | 106 }; |
| 102 | 107 |
| 103 } // namespace content | 108 } // namespace content |
| 104 | 109 |
| 105 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_DELEGATE_H_ | 110 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_DELEGATE_H_ |
| OLD | NEW |