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

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: fix order Created 8 years 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 | « content/content_renderer.gypi ('k') | content/public/browser/web_contents_observer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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..ebb06df06d5f47b64cce12af432778f640bda174 100644
--- a/content/public/browser/web_contents.h
+++ b/content/public/browser/web_contents.h
@@ -393,6 +393,23 @@ class WebContents : public PageNavigator,
// Does this have an opener associated with it?
virtual bool HasOpener() const = 0;
+
+ typedef base::Callback<void(int, /* id */
+ const GURL&, /* image_url */
+ bool, /* errored */
+ int, /* requested_size */
+ const std::vector<SkBitmap>& /* bitmaps*/)>
+ FaviconDownloadCallback;
+
+ // Sends a request to download the given favicon |url| and returns the unique
+ // id of the download request. When the download is finished, |callback| will
+ // be called with the bitmaps received from the renderer. 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,
+ const FaviconDownloadCallback& callback) = 0;
+
};
} // namespace content
« no previous file with comments | « content/content_renderer.gypi ('k') | content/public/browser/web_contents_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698