| Index: components/ntp_tiles/icon_cacher_impl.h
|
| diff --git a/components/ntp_tiles/icon_cacher_impl.h b/components/ntp_tiles/icon_cacher_impl.h
|
| index 1028f72b29b7153cdd64706eaa4bc3623de11b41..86665f651d4aeb83c717b73410f2f841f8c7279d 100644
|
| --- a/components/ntp_tiles/icon_cacher_impl.h
|
| +++ b/components/ntp_tiles/icon_cacher_impl.h
|
| @@ -16,10 +16,12 @@
|
|
|
| namespace favicon {
|
| class FaviconService;
|
| +class LargeIconService;
|
| } // namespace favicon
|
|
|
| namespace favicon_base {
|
| struct FaviconImageResult;
|
| +struct LargeIconResult;
|
| } // namespace favicon_base
|
|
|
| namespace gfx {
|
| @@ -34,12 +36,17 @@ namespace ntp_tiles {
|
|
|
| class IconCacherImpl : public IconCacher {
|
| public:
|
| + // TODO(jkrcal): Make this eventually use only LargeIconService.
|
| + // crbug.com/696563
|
| IconCacherImpl(favicon::FaviconService* favicon_service,
|
| + favicon::LargeIconService* large_icon_service,
|
| std::unique_ptr<image_fetcher::ImageFetcher> image_fetcher);
|
| ~IconCacherImpl() override;
|
|
|
| - void StartFetch(PopularSites::Site site,
|
| - const base::Callback<void(bool)>& done) override;
|
| + void StartFetchPopularSites(PopularSites::Site site,
|
| + const base::Callback<void(bool)>& done) override;
|
| + void StartFetchMostLikely(const GURL& page_url,
|
| + const base::Callback<void(bool)>& done) override;
|
|
|
| private:
|
| void OnGetFaviconImageForPageURLFinished(
|
| @@ -47,13 +54,24 @@ class IconCacherImpl : public IconCacher {
|
| const base::Callback<void(bool)>& done,
|
| const favicon_base::FaviconImageResult& result);
|
|
|
| - void OnFaviconDownloaded(PopularSites::Site site,
|
| - const base::Callback<void(bool)>& done,
|
| - const std::string& id,
|
| - const gfx::Image& fetched_image);
|
| + void OnPopularSitesFaviconDownloaded(PopularSites::Site site,
|
| + const base::Callback<void(bool)>& done,
|
| + const std::string& id,
|
| + const gfx::Image& fetched_image);
|
| +
|
| + void OnGetLargeIconOrFallbackStyleFinished(
|
| + const GURL& page_url,
|
| + const base::Callback<void(bool)>& done,
|
| + const favicon_base::LargeIconResult& result);
|
| +
|
| + void OnMostLikelyFaviconDownloaded(
|
| + const GURL& page_url,
|
| + const base::Callback<void(bool)>& done,
|
| + const favicon_base::LargeIconResult& result);
|
|
|
| base::CancelableTaskTracker tracker_;
|
| favicon::FaviconService* const favicon_service_;
|
| + favicon::LargeIconService* const large_icon_service_;
|
| std::unique_ptr<image_fetcher::ImageFetcher> const image_fetcher_;
|
|
|
| DISALLOW_COPY_AND_ASSIGN(IconCacherImpl);
|
|
|