OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef COMPONENTS_NTP_TILES_ICON_CACHER_IMPL_H_ | 5 #ifndef COMPONENTS_NTP_TILES_ICON_CACHER_IMPL_H_ |
6 #define COMPONENTS_NTP_TILES_ICON_CACHER_IMPL_H_ | 6 #define COMPONENTS_NTP_TILES_ICON_CACHER_IMPL_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 void OnGetFaviconImageForPageURLFinished( | 45 void OnGetFaviconImageForPageURLFinished( |
46 PopularSites::Site site, | 46 PopularSites::Site site, |
47 const base::Callback<void(bool)>& done, | 47 const base::Callback<void(bool)>& done, |
48 const favicon_base::FaviconImageResult& result); | 48 const favicon_base::FaviconImageResult& result); |
49 | 49 |
50 void OnFaviconDownloaded(PopularSites::Site site, | 50 void OnFaviconDownloaded(PopularSites::Site site, |
51 const base::Callback<void(bool)>& done, | 51 const base::Callback<void(bool)>& done, |
52 const std::string& id, | 52 const std::string& id, |
53 const gfx::Image& fetched_image); | 53 const gfx::Image& fetched_image); |
54 | 54 |
| 55 bool ProvideDefaultIcon(const PopularSites::Site& site); |
| 56 void SaveIconForSite(const PopularSites::Site& site, const gfx::Image image); |
| 57 |
55 base::CancelableTaskTracker tracker_; | 58 base::CancelableTaskTracker tracker_; |
56 favicon::FaviconService* const favicon_service_; | 59 favicon::FaviconService* const favicon_service_; |
57 std::unique_ptr<image_fetcher::ImageFetcher> const image_fetcher_; | 60 std::unique_ptr<image_fetcher::ImageFetcher> const image_fetcher_; |
58 | 61 |
59 DISALLOW_COPY_AND_ASSIGN(IconCacherImpl); | 62 DISALLOW_COPY_AND_ASSIGN(IconCacherImpl); |
60 }; | 63 }; |
61 | 64 |
62 } // namespace ntp_tiles | 65 } // namespace ntp_tiles |
63 | 66 |
64 #endif // COMPONENTS_NTP_TILES_ICON_CACHER_IMPL_H_ | 67 #endif // COMPONENTS_NTP_TILES_ICON_CACHER_IMPL_H_ |
OLD | NEW |