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

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: Rebased 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
« no previous file with comments | « no previous file | chrome/browser/bookmarks/bookmark_model.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/bookmarks/bookmark_model.h
diff --git a/chrome/browser/bookmarks/bookmark_model.h b/chrome/browser/bookmarks/bookmark_model.h
index b5089e78e5cf648f125a11fd509532b69c761d8a..f4c263bf25fd3aaa083d4d6703fb33e4b40081a4 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 node'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') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698