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 // File method ordering: Methods in this file are in the same order as | 5 // File method ordering: Methods in this file are in the same order as |
6 // in download_item_impl.h, with the following exception: The public | 6 // in download_item_impl.h, with the following exception: The public |
7 // interface Start is placed in chronological order with the other | 7 // interface Start is placed in chronological order with the other |
8 // (private) routines that together define a DownloadItem's state | 8 // (private) routines that together define a DownloadItem's state |
9 // transitions as the download progresses. See "Download progression | 9 // transitions as the download progresses. See "Download progression |
10 // cascade" later in this file. | 10 // cascade" later in this file. |
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
158 uint32 download_id, | 158 uint32 download_id, |
159 const DownloadCreateInfo& info, | 159 const DownloadCreateInfo& info, |
160 const net::BoundNetLog& bound_net_log) | 160 const net::BoundNetLog& bound_net_log) |
161 : is_save_package_download_(false), | 161 : is_save_package_download_(false), |
162 download_id_(download_id), | 162 download_id_(download_id), |
163 target_disposition_( | 163 target_disposition_( |
164 (info.save_info->prompt_for_save_location) ? | 164 (info.save_info->prompt_for_save_location) ? |
165 TARGET_DISPOSITION_PROMPT : TARGET_DISPOSITION_OVERWRITE), | 165 TARGET_DISPOSITION_PROMPT : TARGET_DISPOSITION_OVERWRITE), |
166 url_chain_(info.url_chain), | 166 url_chain_(info.url_chain), |
167 referrer_url_(info.referrer_url), | 167 referrer_url_(info.referrer_url), |
168 suggested_filename_(UTF16ToUTF8(info.save_info->suggested_name)), | 168 suggested_filename_(base::UTF16ToUTF8(info.save_info->suggested_name)), |
169 forced_file_path_(info.save_info->file_path), | 169 forced_file_path_(info.save_info->file_path), |
170 transition_type_(info.transition_type), | 170 transition_type_(info.transition_type), |
171 has_user_gesture_(info.has_user_gesture), | 171 has_user_gesture_(info.has_user_gesture), |
172 content_disposition_(info.content_disposition), | 172 content_disposition_(info.content_disposition), |
173 mime_type_(info.mime_type), | 173 mime_type_(info.mime_type), |
174 original_mime_type_(info.original_mime_type), | 174 original_mime_type_(info.original_mime_type), |
175 remote_address_(info.remote_address), | 175 remote_address_(info.remote_address), |
176 total_bytes_(info.total_bytes), | 176 total_bytes_(info.total_bytes), |
177 received_bytes_(0), | 177 received_bytes_(0), |
178 bytes_per_sec_(0), | 178 bytes_per_sec_(0), |
(...skipping 1573 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1752 case RESUME_MODE_USER_CONTINUE: | 1752 case RESUME_MODE_USER_CONTINUE: |
1753 return "USER_CONTINUE"; | 1753 return "USER_CONTINUE"; |
1754 case RESUME_MODE_USER_RESTART: | 1754 case RESUME_MODE_USER_RESTART: |
1755 return "USER_RESTART"; | 1755 return "USER_RESTART"; |
1756 } | 1756 } |
1757 NOTREACHED() << "Unknown resume mode " << mode; | 1757 NOTREACHED() << "Unknown resume mode " << mode; |
1758 return "unknown"; | 1758 return "unknown"; |
1759 } | 1759 } |
1760 | 1760 |
1761 } // namespace content | 1761 } // namespace content |
OLD | NEW |