| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "components/offline_pages/downloads/download_ui_item.h" | 5 #include "components/offline_pages/downloads/download_ui_item.h" |
| 6 | 6 |
| 7 namespace offline_pages { | 7 namespace offline_pages { |
| 8 | 8 |
| 9 DownloadUIItem::DownloadUIItem() | 9 DownloadUIItem::DownloadUIItem() |
| 10 : total_bytes(0) { | 10 : total_bytes(0) { |
| 11 } | 11 } |
| 12 | 12 |
| 13 DownloadUIItem::DownloadUIItem(const OfflinePageItem& page) | 13 DownloadUIItem::DownloadUIItem(const OfflinePageItem& page) |
| 14 : guid(page.client_id.id), | 14 : guid(page.client_id.id), |
| 15 url(page.url), | 15 url(page.url), |
| 16 target_path(page.file_path), | 16 target_path(page.file_path), |
| 17 start_time(page.creation_time), | 17 start_time(page.creation_time), |
| 18 total_bytes(page.file_size) {} | 18 total_bytes(page.file_size) {} |
| 19 | 19 |
| 20 DownloadUIItem::DownloadUIItem(const DownloadUIItem& other) |
| 21 : guid(other.guid), |
| 22 url(other.url), |
| 23 target_path(other.target_path), |
| 24 start_time(other.start_time), |
| 25 total_bytes(other.total_bytes) {} |
| 26 |
| 20 DownloadUIItem::~DownloadUIItem() { | 27 DownloadUIItem::~DownloadUIItem() { |
| 21 } | 28 } |
| 22 | 29 |
| 23 } // namespace offline_pages | 30 } // namespace offline_pages |
| OLD | NEW |