| 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_CORE_FAVICON_DRIVER_IMPL_H_ | 5 #ifndef COMPONENTS_FAVICON_CORE_FAVICON_DRIVER_IMPL_H_ |
| 6 #define COMPONENTS_FAVICON_CORE_FAVICON_DRIVER_IMPL_H_ | 6 #define COMPONENTS_FAVICON_CORE_FAVICON_DRIVER_IMPL_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 30 matching lines...) Expand all Loading... |
| 41 void FetchFavicon(const GURL& url) override; | 41 void FetchFavicon(const GURL& url) override; |
| 42 | 42 |
| 43 // FaviconHandler::Delegate implementation. | 43 // FaviconHandler::Delegate implementation. |
| 44 bool IsBookmarked(const GURL& url) override; | 44 bool IsBookmarked(const GURL& url) override; |
| 45 | 45 |
| 46 // Returns whether the driver is waiting for a download to complete or for | 46 // Returns whether the driver is waiting for a download to complete or for |
| 47 // data from the FaviconService. Reserved for testing. | 47 // data from the FaviconService. Reserved for testing. |
| 48 bool HasPendingTasksForTest(); | 48 bool HasPendingTasksForTest(); |
| 49 | 49 |
| 50 protected: | 50 protected: |
| 51 FaviconDriverImpl(FaviconService* favicon_service, | 51 FaviconDriverImpl(bool enable_touch_icons, |
| 52 FaviconService* favicon_service, |
| 52 history::HistoryService* history_service, | 53 history::HistoryService* history_service, |
| 53 bookmarks::BookmarkModel* bookmark_model); | 54 bookmarks::BookmarkModel* bookmark_model); |
| 54 ~FaviconDriverImpl() override; | 55 ~FaviconDriverImpl() override; |
| 55 | 56 |
| 56 // Returns whether downloading favicon for |url| previously failed. | 57 // Returns whether downloading favicon for |url| previously failed. |
| 57 bool WasUnableToDownloadFavicon(const GURL& url); | 58 bool WasUnableToDownloadFavicon(const GURL& url); |
| 58 | 59 |
| 59 // Informs FaviconService that the favicon for |url| is out of date. If | 60 // Informs FaviconService that the favicon for |url| is out of date. If |
| 60 // |force_reload| is true, then discard information about favicon download | 61 // |force_reload| is true, then discard information about favicon download |
| 61 // failures. | 62 // failures. |
| (...skipping 19 matching lines...) Expand all Loading... |
| 81 // |touch_icon_handler_| may be null depending on the platform and variations. | 82 // |touch_icon_handler_| may be null depending on the platform and variations. |
| 82 std::unique_ptr<FaviconHandler> favicon_handler_; | 83 std::unique_ptr<FaviconHandler> favicon_handler_; |
| 83 std::unique_ptr<FaviconHandler> touch_icon_handler_; | 84 std::unique_ptr<FaviconHandler> touch_icon_handler_; |
| 84 | 85 |
| 85 DISALLOW_COPY_AND_ASSIGN(FaviconDriverImpl); | 86 DISALLOW_COPY_AND_ASSIGN(FaviconDriverImpl); |
| 86 }; | 87 }; |
| 87 | 88 |
| 88 } // namespace favicon | 89 } // namespace favicon |
| 89 | 90 |
| 90 #endif // COMPONENTS_FAVICON_CORE_FAVICON_DRIVER_IMPL_H_ | 91 #endif // COMPONENTS_FAVICON_CORE_FAVICON_DRIVER_IMPL_H_ |
| OLD | NEW |