| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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_SAVE_TYPES_H__ | 5 #ifndef CHROME_BROWSER_DOWNLOAD_SAVE_TYPES_H__ |
| 6 #define CHROME_BROWSER_DOWNLOAD_SAVE_TYPES_H__ | 6 #define CHROME_BROWSER_DOWNLOAD_SAVE_TYPES_H__ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 SAVE_FILE_FROM_FILE | 28 SAVE_FILE_FROM_FILE |
| 29 }; | 29 }; |
| 30 | 30 |
| 31 SaveFileCreateInfo(const std::wstring& path, | 31 SaveFileCreateInfo(const std::wstring& path, |
| 32 const std::wstring& url, | 32 const std::wstring& url, |
| 33 SaveFileSource save_source, | 33 SaveFileSource save_source, |
| 34 int32 save_id) | 34 int32 save_id) |
| 35 : path(path), | 35 : path(path), |
| 36 url(url), | 36 url(url), |
| 37 save_id(save_id), | 37 save_id(save_id), |
| 38 save_source(save_source), | |
| 39 render_process_id(-1), | 38 render_process_id(-1), |
| 40 render_view_id(-1), | 39 render_view_id(-1), |
| 41 request_id(-1), | 40 request_id(-1), |
| 42 total_bytes(0) { | 41 total_bytes(0), |
| 42 save_source(save_source) { |
| 43 } | 43 } |
| 44 | 44 |
| 45 SaveFileCreateInfo() : save_id(-1) {} | 45 SaveFileCreateInfo() : save_id(-1) {} |
| 46 | 46 |
| 47 // SaveItem fields. | 47 // SaveItem fields. |
| 48 // The local file path of saved file. | 48 // The local file path of saved file. |
| 49 std::wstring path; | 49 std::wstring path; |
| 50 // Original URL of the saved resource. | 50 // Original URL of the saved resource. |
| 51 std::wstring url; | 51 std::wstring url; |
| 52 // Final URL of the saved resource since some URL might be redirected. | 52 // Final URL of the saved resource since some URL might be redirected. |
| 53 std::wstring final_url; | 53 std::wstring final_url; |
| 54 // The unique identifier for saving job, assigned at creation by | 54 // The unique identifier for saving job, assigned at creation by |
| 55 // the SaveFileManager for its internal record keeping. | 55 // the SaveFileManager for its internal record keeping. |
| 56 int save_id; | 56 int save_id; |
| 57 // IDs for looking up the tab we are associated with. | 57 // IDs for looking up the tab we are associated with. |
| 58 int render_process_id; | 58 int render_process_id; |
| 59 int render_view_id; | 59 int render_view_id; |
| 60 // Handle for informing the ResourceDispatcherHost of a UI based cancel. | 60 // Handle for informing the ResourceDispatcherHost of a UI based cancel. |
| 61 int request_id; | 61 int request_id; |
| 62 // Disposition info from HTTP response. | 62 // Disposition info from HTTP response. |
| 63 std::string content_disposition; | 63 std::string content_disposition; |
| 64 // Total bytes of saved file. | 64 // Total bytes of saved file. |
| 65 int64 total_bytes; | 65 int64 total_bytes; |
| 66 // Source type of saved file. | 66 // Source type of saved file. |
| 67 SaveFileSource save_source; | 67 SaveFileSource save_source; |
| 68 }; | 68 }; |
| 69 | 69 |
| 70 #endif // CHROME_BROWSER_DOWNLOAD_SAVE_TYPES_H__ | 70 #endif // CHROME_BROWSER_DOWNLOAD_SAVE_TYPES_H__ |
| 71 | 71 |
| OLD | NEW |