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

Unified Diff: components/ntp_snippets/content_suggestion.h

Issue 2811123003: [Content suggestions] Allow to specify URLs for favicons (Closed)
Patch Set: Marc's comments #3 Created 3 years, 8 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
« no previous file with comments | « no previous file | components/ntp_snippets/content_suggestions_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/ntp_snippets/content_suggestion.h
diff --git a/components/ntp_snippets/content_suggestion.h b/components/ntp_snippets/content_suggestion.h
index 75f3d4c9b9cfb4e7ded26759d9e7fc326fcc86ef..7879a552ab144a4cc269de0162be90ff9d648720 100644
--- a/components/ntp_snippets/content_suggestion.h
+++ b/components/ntp_snippets/content_suggestion.h
@@ -112,6 +112,14 @@ class ContentSuggestion {
// This may be an AMP URL.
const GURL& url() const { return url_; }
+ // The URL of a page that links to a favicon that represents the suggestion.
+ const GURL& url_with_favicon() const {
+ return url_with_favicon_.is_valid() ? url_with_favicon_ : url_;
+ }
+ void set_url_with_favicon(const GURL& url_with_favicon) {
+ url_with_favicon_ = url_with_favicon;
+ }
+
// Title of the suggestion.
const base::string16& title() const { return title_; }
void set_title(const base::string16& title) { title_ = title; }
@@ -186,6 +194,7 @@ class ContentSuggestion {
private:
ID id_;
GURL url_;
+ GURL url_with_favicon_;
base::string16 title_;
base::string16 snippet_text_;
base::Time publish_date_;
« no previous file with comments | « no previous file | components/ntp_snippets/content_suggestions_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698