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

Unified Diff: components/favicon/ios/web_favicon_driver.h

Issue 2691933004: Avoid cyclic dependency FaviconHandler<-->FaviconDriverImpl (Closed)
Patch Set: Created 3 years, 10 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
Index: components/favicon/ios/web_favicon_driver.h
diff --git a/components/favicon/ios/web_favicon_driver.h b/components/favicon/ios/web_favicon_driver.h
index b5209a1b7a0a5067db20c93bb3e054ad3e18fcef..23cb2f63531fd286e436acf5c18c475014c5f84a 100644
--- a/components/favicon/ios/web_favicon_driver.h
+++ b/components/favicon/ios/web_favicon_driver.h
@@ -7,6 +7,7 @@
#include "base/macros.h"
#include "components/favicon/core/favicon_driver_impl.h"
+#include "components/favicon/core/favicon_handler.h"
#include "ios/web/public/web_state/web_state_observer.h"
#include "ios/web/public/web_state/web_state_user_data.h"
@@ -21,6 +22,7 @@ namespace favicon {
// favicon download has completed.
class WebFaviconDriver : public web::WebStateObserver,
public web::WebStateUserData<WebFaviconDriver>,
+ public FaviconHandler::Delegate,
public FaviconDriverImpl {
public:
static void CreateForWebState(web::WebState* web_state,
@@ -32,9 +34,13 @@ class WebFaviconDriver : public web::WebStateObserver,
void FetchFavicon(const GURL& url) override;
gfx::Image GetFavicon() const override;
bool FaviconIsValid() const override;
- int StartDownload(const GURL& url, int max_bitmap_size) override;
- bool IsOffTheRecord() override;
GURL GetActiveURL() override;
+
+ // FaviconHandler::Delegate implementation.
+ int DownloadImage(const GURL& url,
+ int max_image_size,
+ ImageDownloadCallback callback) override;
+ bool IsOffTheRecord() override;
void OnFaviconUpdated(
const GURL& page_url,
FaviconDriverObserver::NotificationIconType notification_icon_type,

Powered by Google App Engine
This is Rietveld 408576698