| 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_FILE_H_ | 5 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_FILE_H_ |
| 6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_FILE_H_ | 6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_FILE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 71 virtual bool GetHash(std::string* hash) = 0; | 71 virtual bool GetHash(std::string* hash) = 0; |
| 72 | 72 |
| 73 // Returns the current (intermediate) state of the hash as a byte string. | 73 // Returns the current (intermediate) state of the hash as a byte string. |
| 74 virtual std::string GetHashState() = 0; | 74 virtual std::string GetHashState() = 0; |
| 75 | 75 |
| 76 // Set the application GUID to be used to identify the app to the | 76 // Set the application GUID to be used to identify the app to the |
| 77 // system AV function when scanning downloaded files. Should be called | 77 // system AV function when scanning downloaded files. Should be called |
| 78 // before RenameAndAnnotate() to take effect. | 78 // before RenameAndAnnotate() to take effect. |
| 79 virtual void SetClientGuid(const std::string& guid) = 0; | 79 virtual void SetClientGuid(const std::string& guid) = 0; |
| 80 | 80 |
| 81 // Set the download file's extension's visibility in the Finder (Mac). |
| 82 virtual void SetHideFileExtension(bool hide_extension) = 0; |
| 83 |
| 81 // For testing. Must be called on FILE thread. | 84 // For testing. Must be called on FILE thread. |
| 82 // TODO(rdsmith): Replace use of EnsureNoPendingDownloads() | 85 // TODO(rdsmith): Replace use of EnsureNoPendingDownloads() |
| 83 // on the DownloadManager with a test-specific DownloadFileFactory | 86 // on the DownloadManager with a test-specific DownloadFileFactory |
| 84 // which keeps track of the number of DownloadFiles. | 87 // which keeps track of the number of DownloadFiles. |
| 85 static int GetNumberOfDownloadFiles(); | 88 static int GetNumberOfDownloadFiles(); |
| 86 | 89 |
| 87 protected: | 90 protected: |
| 88 static int number_active_objects_; | 91 static int number_active_objects_; |
| 89 }; | 92 }; |
| 90 | 93 |
| 91 } // namespace content | 94 } // namespace content |
| 92 | 95 |
| 93 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_FILE_H_ | 96 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_FILE_H_ |
| OLD | NEW |