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

Unified Diff: components/offline_pages/core/prefetch/prefetch_service_impl.cc

Issue 2864293003: [Offline Pages] Add a GCMAppHandler for offline page prefetch. (Closed)
Patch Set: Fix windows compile. Created 3 years, 7 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/core/prefetch/prefetch_service_impl.cc
diff --git a/components/offline_pages/core/prefetch/prefetch_service_impl.cc b/components/offline_pages/core/prefetch/prefetch_service_impl.cc
index 9e86aba0b591bdd968aaa7e42cfabc1545323a42..f992698fdbc59bbf2dc18d15c57aaa9e2bd6ad58 100644
--- a/components/offline_pages/core/prefetch/prefetch_service_impl.cc
+++ b/components/offline_pages/core/prefetch/prefetch_service_impl.cc
@@ -16,9 +16,20 @@ PrefetchServiceImpl::PrefetchServiceImpl()
PrefetchServiceImpl::~PrefetchServiceImpl() = default;
+void PrefetchServiceImpl::ObserveContentSuggestionsService(
+ ntp_snippets::ContentSuggestionsService* service) {
fgorski 2017/05/30 18:20:05 CHECK or DCHECK to ensure we are not passing in th
dewittj 2017/05/30 21:09:18 Not going to change this code in this patch.
+ suggested_articles_observer_ =
+ base::MakeUnique<SuggestedArticlesObserver>(service, this);
+}
+
+void PrefetchServiceImpl::AddPrefetchGCMHandler(
+ std::unique_ptr<PrefetchGCMHandler> app_handler) {
+ gcm_handler_ = std::move(app_handler);
+}
+
PrefetchDispatcher* PrefetchServiceImpl::GetDispatcher() {
return dispatcher_.get();
-};
+}
void PrefetchServiceImpl::Shutdown() {}

Powered by Google App Engine
This is Rietveld 408576698