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

Unified Diff: content/public/browser/web_contents.h

Issue 11411180: move favicon download code from chrome/ into content/ (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: content/public/browser/web_contents.h
diff --git a/content/public/browser/web_contents.h b/content/public/browser/web_contents.h
index cab59f04bc062e0206b3a1a294ff28e94e41afb6..0b0ad43169e80cb19ec3131e67e47ca4ed7be609 100644
--- a/content/public/browser/web_contents.h
+++ b/content/public/browser/web_contents.h
@@ -36,6 +36,7 @@ struct LoadStateWithParam;
namespace content {
class BrowserContext;
+class FaviconDownloadDelegate;
class InterstitialPage;
class RenderProcessHost;
class RenderViewHost;
@@ -393,6 +394,18 @@ class WebContents : public PageNavigator,
// Does this have an opener associated with it?
virtual bool HasOpener() const = 0;
+
+ // Starts the download of the given favicon |url| and returns the unique id of
+ // the download request. When the download is finished, an
+ // IconHostMsg_DidDownloadFavicon IPC message will be sent and passed on to
+ // the delegate via FaviconDownloadDelegate::DidDownloadFavicon().
+ // Note that |image_size| is a hint for images with multiple sizes. The
+ // downloaded image is not resized to the given image_size. If 0 is passed,
+ // the first frame of the image is returned.
+ virtual int DownloadFavicon(const GURL& url, int image_size) = 0;
jam 2012/11/27 01:16:31 nit: comment is out of date (re IPC) seems that a
Cait (Slow) 2012/11/28 00:11:45 Fixed the comment. Unfortunately, the delegate has
jam 2012/11/28 04:08:16 can the updated url be saved in WebContents until
+
+ virtual void RegisterFaviconDelegate(FaviconDownloadDelegate* delegate) = 0;
+
};
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698