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

Unified Diff: chrome/browser/fav_icon_helper.h

Issue 149239: Split out some of the RVHDelegate functions into separate sub-classes. To lim... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 5 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 | chrome/browser/fav_icon_helper.cc » ('j') | chrome/browser/renderer_host/render_view_host.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/fav_icon_helper.h
===================================================================
--- chrome/browser/fav_icon_helper.h (revision 19988)
+++ chrome/browser/fav_icon_helper.h (working copy)
@@ -12,6 +12,7 @@
#include "base/scoped_ptr.h"
#include "chrome/browser/cancelable_request.h"
#include "chrome/browser/history/history.h"
+#include "chrome/browser/renderer_host/render_view_host_delegate.h"
#include "chrome/common/ref_counted_util.h"
#include "googleurl/src/gurl.h"
@@ -61,17 +62,13 @@
// at which point we update the favicon of the NavigationEntry and notify
// the database to save the favicon.
-class FavIconHelper {
+class FavIconHelper : public RenderViewHostDelegate::FavIcon {
public:
explicit FavIconHelper(TabContents* tab_contents);
// Initiates loading the favicon for the specified url.
void FetchFavIcon(const GURL& url);
- // Sets the url of the favicon for the specified page. This is invoked some
- // time after FetchFavIcon.
- void SetFavIconURL(const GURL& icon_url);
-
// Sets the image data for the favicon. This is invoked asynchronously after
// we request the TabContents to download the favicon.
void SetFavIcon(int download_id,
@@ -100,6 +97,16 @@
GURL fav_icon_url;
};
+ // RenderViewHostDelegate::Favicon implementation.
+ virtual void DidDownloadImage(RenderViewHost* render_view_host,
+ int id,
+ const GURL& image_url,
+ bool errored,
+ const SkBitmap& image);
+ virtual void UpdateFavIconURL(RenderViewHost* render_view_host,
+ int32 page_id,
+ const GURL& icon_url);
+
// Return the NavigationEntry for the active entry, or NULL if the active
// entries URL does not match that of the URL last passed to FetchFavIcon.
NavigationEntry* GetEntry();
« no previous file with comments | « no previous file | chrome/browser/fav_icon_helper.cc » ('j') | chrome/browser/renderer_host/render_view_host.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698