Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(764)

Unified Diff: components/offline_pages/downloads/download_ui_item.cc

Issue 2260963003: [Offline pages] Enabling notifications for pages saved later (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Adding tests Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/offline_pages/downloads/download_ui_item.cc
diff --git a/components/offline_pages/downloads/download_ui_item.cc b/components/offline_pages/downloads/download_ui_item.cc
index df8fd133c1e2f921368bbc128c8ae2d3392e3dab..95e26117fc7460ae327f35829a49f104d5e11c99 100644
--- a/components/offline_pages/downloads/download_ui_item.cc
+++ b/components/offline_pages/downloads/download_ui_item.cc
@@ -4,6 +4,9 @@
#include "components/offline_pages/downloads/download_ui_item.h"
+#include "components/offline_pages/background/save_page_request.h"
+#include "components/offline_pages/offline_page_item.h"
+
namespace offline_pages {
DownloadUIItem::DownloadUIItem()
@@ -18,6 +21,12 @@ DownloadUIItem::DownloadUIItem(const OfflinePageItem& page)
start_time(page.creation_time),
total_bytes(page.file_size) {}
+DownloadUIItem::DownloadUIItem(const SavePageRequest& request)
+ : guid(request.client_id().id),
+ url(request.url()),
+ start_time(request.creation_time()),
+ total_bytes(-1L) {}
+
DownloadUIItem::DownloadUIItem(const DownloadUIItem& other)
: guid(other.guid),
url(other.url),
Dmitry Titov 2016/08/24 00:29:35 I know it's not part of your patch, but I've notic
fgorski 2016/08/24 18:25:23 Done. Good catch.

Powered by Google App Engine
This is Rietveld 408576698