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

Unified Diff: chrome/browser/bookmarks/bookmark_model.h

Issue 11428004: Sync the bookmark's icon URL (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month 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/bookmarks/bookmark_model.h
diff --git a/chrome/browser/bookmarks/bookmark_model.h b/chrome/browser/bookmarks/bookmark_model.h
index 91d960e89e502c3c617d959a87db90f2e715423c..5653ac432d73232e8731a92da61cd61d095178ce 100644
--- a/chrome/browser/bookmarks/bookmark_model.h
+++ b/chrome/browser/bookmarks/bookmark_model.h
@@ -79,6 +79,10 @@ class BookmarkNode : public ui::TreeNode<BookmarkNode> {
const GURL& url() const { return url_; }
void set_url(const GURL& url) { url_ = url; }
+ // Returns the favicon's URL. Returns an empty URL if there is no favicon
+ // associated with this bookmark.
+ const GURL& icon_url() const { return icon_url_; }
+
Type type() const { return type_; }
void set_type(Type type) { type_ = type; }
@@ -133,6 +137,11 @@ class BookmarkNode : public ui::TreeNode<BookmarkNode> {
// Called when the favicon becomes invalid.
void InvalidateFavicon();
+ // Sets the favicon's URL.
+ void set_icon_url(const GURL& icon_url) {
+ icon_url_ = icon_url;
+ }
+
const gfx::Image& favicon() const { return favicon_; }
void set_favicon(const gfx::Image& icon) { favicon_ = icon; }
@@ -165,6 +174,9 @@ class BookmarkNode : public ui::TreeNode<BookmarkNode> {
// The favicon of this node.
gfx::Image favicon_;
+ // The URL of the bookmark's favicon.
+ GURL icon_url_;
+
// The loading state of the favicon.
FaviconState favicon_state_;
« no previous file with comments | « no previous file | chrome/browser/bookmarks/bookmark_model.cc » ('j') | chrome/browser/sync/test/integration/bookmarks_helper.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698