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

Unified Diff: components/ntp_snippets/ntp_snippets_service.h

Issue 1980033002: [NTP Snippets] Clear the snippets when the user signs out (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix double we Created 4 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/ntp_snippets/ntp_snippets_service.h
diff --git a/components/ntp_snippets/ntp_snippets_service.h b/components/ntp_snippets/ntp_snippets_service.h
index 13e949afb04dd48467f35c90321bb8acf9c4e08f..7144e451fcebd46e1a3ee87f5c405026455718ef 100644
--- a/components/ntp_snippets/ntp_snippets_service.h
+++ b/components/ntp_snippets/ntp_snippets_service.h
@@ -198,6 +198,11 @@ class NTPSnippetsServiceObserver {
virtual void NTPSnippetsServiceLoaded() = 0;
// Sent when the service is shutting down.
virtual void NTPSnippetsServiceShutdown() = 0;
+ // Sent every time the service has its data sources cleared.
+ // Note: we use it as signal that the user signed out or disabled sync, but it
+ // can be triggered in other cases, when the suggestions service returns no
+ // hosts. (e.g. the user manually removed all MostLikely tiles.)
+ virtual void NTPSnippetsServiceCleared() = 0;
protected:
virtual ~NTPSnippetsServiceObserver() {}

Powered by Google App Engine
This is Rietveld 408576698