| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 #include "chrome/browser/history/download_create_info.h" | 5 #include "chrome/browser/history/download_create_info.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/format_macros.h" | 9 #include "base/format_macros.h" |
| 10 #include "base/stringprintf.h" | 10 #include "base/stringprintf.h" |
| 11 | 11 |
| 12 DownloadCreateInfo::DownloadCreateInfo(const FilePath& path, | 12 DownloadCreateInfo::DownloadCreateInfo(const FilePath& path, |
| 13 const GURL& url, | 13 const GURL& url, |
| 14 base::Time start_time, | 14 base::Time start_time, |
| 15 int64 received_bytes, | 15 int64 received_bytes, |
| 16 int64 total_bytes, | 16 int64 total_bytes, |
| 17 int32 state, | 17 int32 state, |
| 18 int32 download_id) | 18 int32 download_id, |
| 19 bool has_user_gesture) |
| 19 : path(path), | 20 : path(path), |
| 20 url(url), | 21 url(url), |
| 21 path_uniquifier(0), | 22 path_uniquifier(0), |
| 22 start_time(start_time), | 23 start_time(start_time), |
| 23 received_bytes(received_bytes), | 24 received_bytes(received_bytes), |
| 24 total_bytes(total_bytes), | 25 total_bytes(total_bytes), |
| 25 state(state), | 26 state(state), |
| 26 download_id(download_id), | 27 download_id(download_id), |
| 28 has_user_gesture(has_user_gesture), |
| 27 child_id(-1), | 29 child_id(-1), |
| 28 render_view_id(-1), | 30 render_view_id(-1), |
| 29 request_id(-1), | 31 request_id(-1), |
| 30 db_handle(0), | 32 db_handle(0), |
| 31 prompt_user_for_save_location(false), | 33 prompt_user_for_save_location(false), |
| 32 is_dangerous(false), | 34 is_dangerous(false), |
| 33 is_extension_install(false) { | 35 is_extension_install(false) { |
| 34 } | 36 } |
| 35 | 37 |
| 36 DownloadCreateInfo::DownloadCreateInfo() | 38 DownloadCreateInfo::DownloadCreateInfo() |
| 37 : path_uniquifier(0), | 39 : path_uniquifier(0), |
| 38 received_bytes(0), | 40 received_bytes(0), |
| 39 total_bytes(0), | 41 total_bytes(0), |
| 40 state(-1), | 42 state(-1), |
| 41 download_id(-1), | 43 download_id(-1), |
| 44 has_user_gesture(has_user_gesture), |
| 42 child_id(-1), | 45 child_id(-1), |
| 43 render_view_id(-1), | 46 render_view_id(-1), |
| 44 request_id(-1), | 47 request_id(-1), |
| 45 db_handle(0), | 48 db_handle(0), |
| 46 prompt_user_for_save_location(false), | 49 prompt_user_for_save_location(false), |
| 47 is_dangerous(false), | 50 is_dangerous(false), |
| 48 is_extension_install(false) { | 51 is_extension_install(false) { |
| 49 } | 52 } |
| 50 | 53 |
| 51 DownloadCreateInfo::~DownloadCreateInfo() { | 54 DownloadCreateInfo::~DownloadCreateInfo() { |
| (...skipping 15 matching lines...) Expand all Loading... |
| 67 path.value().c_str(), | 70 path.value().c_str(), |
| 68 received_bytes, | 71 received_bytes, |
| 69 total_bytes, | 72 total_bytes, |
| 70 child_id, | 73 child_id, |
| 71 render_view_id, | 74 render_view_id, |
| 72 request_id, | 75 request_id, |
| 73 download_id, | 76 download_id, |
| 74 prompt_user_for_save_location ? 'T' : 'F'); | 77 prompt_user_for_save_location ? 'T' : 'F'); |
| 75 } | 78 } |
| 76 | 79 |
| OLD | NEW |