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

Unified Diff: chrome/browser/ui/webui/snippets_internals_ui.cc

Issue 2569663004: [NTPSnippets] Switch from TickClock to Clock for storing the last background fetched time. (Closed)
Patch Set: Add a DCHECK to check that the num or args passed to the new method is 0 Created 4 years 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: chrome/browser/ui/webui/snippets_internals_ui.cc
diff --git a/chrome/browser/ui/webui/snippets_internals_ui.cc b/chrome/browser/ui/webui/snippets_internals_ui.cc
index 24f185a0a20c8aeac9c8a0397e4523e62c507828..28f685634266fcfe5413374f841686f7cc419c09 100644
--- a/chrome/browser/ui/webui/snippets_internals_ui.cc
+++ b/chrome/browser/ui/webui/snippets_internals_ui.cc
@@ -4,6 +4,7 @@
#include "chrome/browser/ui/webui/snippets_internals_ui.h"
+#include "chrome/browser/ntp_snippets/content_suggestions_service_factory.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ui/webui/snippets_internals_message_handler.h"
#include "chrome/common/url_constants.h"
@@ -31,7 +32,9 @@ SnippetsInternalsUI::SnippetsInternalsUI(content::WebUI* web_ui)
Profile* profile = Profile::FromWebUI(web_ui);
content::WebUIDataSource::Add(profile, CreateSnippetsInternalsHTMLSource());
- web_ui->AddMessageHandler(new SnippetsInternalsMessageHandler);
+ web_ui->AddMessageHandler(new SnippetsInternalsMessageHandler(
+ ContentSuggestionsServiceFactory::GetInstance()->GetForProfile(profile),
+ profile->GetPrefs()));
}
SnippetsInternalsUI::~SnippetsInternalsUI() {}

Powered by Google App Engine
This is Rietveld 408576698