| Index: components/ntp_snippets/content_suggestions_provider.h
|
| diff --git a/components/ntp_snippets/content_suggestions_provider.h b/components/ntp_snippets/content_suggestions_provider.h
|
| index 23d403c44dc5012e025e00df10fac45e96e07e5a..836fd41996ddd1d2589959e73426e70f72194709 100644
|
| --- a/components/ntp_snippets/content_suggestions_provider.h
|
| +++ b/components/ntp_snippets/content_suggestions_provider.h
|
| @@ -64,6 +64,19 @@ class ContentSuggestionsProvider {
|
| virtual void OnCategoryStatusChanged(ContentSuggestionsProvider* provider,
|
| Category category,
|
| CategoryStatus new_status) = 0;
|
| +
|
| + // Called when a suggestion has been invalidated. It will not be provided
|
| + // through |OnNewSuggestions| anymore, is not supported by
|
| + // |FetchSuggestionImage| or |DismissSuggestion| anymore, and should
|
| + // immediately be cleared from the UI and caches. This happens, for example,
|
| + // when the content that the suggestion refers to is gone.
|
| + // Note that this event may be fired even if the corresponding |category| is
|
| + // not currently AVAILABLE, because open UIs may still be showing the
|
| + // suggestion that is to be removed. This event may also be fired for
|
| + // |suggestion_id|s that never existed and should be ignored in that case.
|
| + virtual void OnSuggestionInvalidated(ContentSuggestionsProvider* provider,
|
| + Category category,
|
| + const std::string& suggestion_id) = 0;
|
| };
|
|
|
| virtual ~ContentSuggestionsProvider();
|
|
|