OLD | NEW |
---|---|
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_FAVICON_IOS_WEB_FAVICON_DRIVER_H_ | 5 #ifndef COMPONENTS_FAVICON_IOS_WEB_FAVICON_DRIVER_H_ |
6 #define COMPONENTS_FAVICON_IOS_WEB_FAVICON_DRIVER_H_ | 6 #define COMPONENTS_FAVICON_IOS_WEB_FAVICON_DRIVER_H_ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "components/favicon/core/favicon_driver_impl.h" | 9 #include "components/favicon/core/favicon_driver_impl.h" |
10 #import "components/image_fetcher/ios/ios_image_data_fetcher_wrapper.h" | |
mef
2017/02/06 16:36:17
is this #import needed here if you forward declare
sdefresne
2017/02/06 17:33:33
I think the import is required as the image_fetche
gambard
2017/02/07 10:03:33
Yes, sorry.
| |
10 #include "ios/web/public/web_state/web_state_observer.h" | 11 #include "ios/web/public/web_state/web_state_observer.h" |
11 #include "ios/web/public/web_state/web_state_user_data.h" | 12 #include "ios/web/public/web_state/web_state_user_data.h" |
12 | 13 |
14 namespace image_fetcher { | |
15 class IOSImageDataFetcherWrapper; | |
sdefresne
2017/02/06 17:33:33
Remove.
gambard
2017/02/07 10:03:33
Done.
| |
16 } | |
17 | |
13 namespace web { | 18 namespace web { |
14 class WebState; | 19 class WebState; |
15 } | 20 } |
16 | 21 |
17 namespace favicon { | 22 namespace favicon { |
18 | 23 |
19 // WebFaviconDriver is an implementation of FaviconDriver that listen to | 24 // WebFaviconDriver is an implementation of FaviconDriver that listen to |
20 // WebState events to start download of favicons and to get informed when the | 25 // WebState events to start download of favicons and to get informed when the |
21 // favicon download has completed. | 26 // favicon download has completed. |
22 class WebFaviconDriver : public web::WebStateObserver, | 27 class WebFaviconDriver : public web::WebStateObserver, |
(...skipping 28 matching lines...) Expand all Loading... | |
51 bookmarks::BookmarkModel* bookmark_model); | 56 bookmarks::BookmarkModel* bookmark_model); |
52 ~WebFaviconDriver() override; | 57 ~WebFaviconDriver() override; |
53 | 58 |
54 // web::WebStateObserver implementation. | 59 // web::WebStateObserver implementation. |
55 void FaviconUrlUpdated( | 60 void FaviconUrlUpdated( |
56 const std::vector<web::FaviconURL>& candidates) override; | 61 const std::vector<web::FaviconURL>& candidates) override; |
57 | 62 |
58 // The URL passed to FetchFavicon(). | 63 // The URL passed to FetchFavicon(). |
59 GURL fetch_favicon_url_; | 64 GURL fetch_favicon_url_; |
60 | 65 |
66 // Image Fetcher used to fetch favicon. | |
67 image_fetcher::IOSImageDataFetcherWrapper image_fetcher_; | |
68 | |
61 DISALLOW_COPY_AND_ASSIGN(WebFaviconDriver); | 69 DISALLOW_COPY_AND_ASSIGN(WebFaviconDriver); |
62 }; | 70 }; |
63 | 71 |
64 } // namespace favicon | 72 } // namespace favicon |
65 | 73 |
66 #endif // COMPONENTS_FAVICON_IOS_WEB_FAVICON_DRIVER_H_ | 74 #endif // COMPONENTS_FAVICON_IOS_WEB_FAVICON_DRIVER_H_ |
OLD | NEW |