| 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_SNIPPETS_OFFLINE_PAGES_RECENT_TAB_SUGGESTIONS_PROVIDER_H_ | 5 #ifndef COMPONENTS_NTP_SNIPPETS_OFFLINE_PAGES_RECENT_TAB_SUGGESTIONS_PROVIDER_H_ |
| 6 #define COMPONENTS_NTP_SNIPPETS_OFFLINE_PAGES_RECENT_TAB_SUGGESTIONS_PROVIDER_H_ | 6 #define COMPONENTS_NTP_SNIPPETS_OFFLINE_PAGES_RECENT_TAB_SUGGESTIONS_PROVIDER_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 61 | 61 |
| 62 private: | 62 private: |
| 63 friend class RecentTabSuggestionsProviderTest; | 63 friend class RecentTabSuggestionsProviderTest; |
| 64 | 64 |
| 65 void GetPagesMatchingQueryCallbackForGetDismissedSuggestions( | 65 void GetPagesMatchingQueryCallbackForGetDismissedSuggestions( |
| 66 const DismissedSuggestionsCallback& callback, | 66 const DismissedSuggestionsCallback& callback, |
| 67 const std::vector<offline_pages::OfflinePageItem>& offline_pages) const; | 67 const std::vector<offline_pages::OfflinePageItem>& offline_pages) const; |
| 68 | 68 |
| 69 // OfflinePageModel::Observer implementation. | 69 // OfflinePageModel::Observer implementation. |
| 70 void OfflinePageModelLoaded(offline_pages::OfflinePageModel* model) override; | 70 void OfflinePageModelLoaded(offline_pages::OfflinePageModel* model) override; |
| 71 void OfflinePageModelChanged(offline_pages::OfflinePageModel* model) override; | 71 void OfflinePageAdded( |
| 72 offline_pages::OfflinePageModel* model, |
| 73 const offline_pages::OfflinePageItem& added_page) override; |
| 72 void OfflinePageDeleted(int64_t offline_id, | 74 void OfflinePageDeleted(int64_t offline_id, |
| 73 const offline_pages::ClientId& client_id) override; | 75 const offline_pages::ClientId& client_id) override; |
| 74 | 76 |
| 75 void GetPagesMatchingQueryCallbackForFetchRecentTabs( | 77 void GetPagesMatchingQueryCallbackForFetchRecentTabs( |
| 76 const std::vector<offline_pages::OfflinePageItem>& offline_pages); | 78 const std::vector<offline_pages::OfflinePageItem>& offline_pages); |
| 77 | 79 |
| 78 // Updates the |category_status_| of the |provided_category_| and notifies the | 80 // Updates the |category_status_| of the |provided_category_| and notifies the |
| 79 // |observer_|, if necessary. | 81 // |observer_|, if necessary. |
| 80 void NotifyStatusChanged(CategoryStatus new_status); | 82 void NotifyStatusChanged(CategoryStatus new_status); |
| 81 | 83 |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 113 PrefService* pref_service_; | 115 PrefService* pref_service_; |
| 114 | 116 |
| 115 base::WeakPtrFactory<RecentTabSuggestionsProvider> weak_ptr_factory_; | 117 base::WeakPtrFactory<RecentTabSuggestionsProvider> weak_ptr_factory_; |
| 116 | 118 |
| 117 DISALLOW_COPY_AND_ASSIGN(RecentTabSuggestionsProvider); | 119 DISALLOW_COPY_AND_ASSIGN(RecentTabSuggestionsProvider); |
| 118 }; | 120 }; |
| 119 | 121 |
| 120 } // namespace ntp_snippets | 122 } // namespace ntp_snippets |
| 121 | 123 |
| 122 #endif // COMPONENTS_NTP_SNIPPETS_OFFLINE_PAGES_RECENT_TAB_SUGGESTIONS_PROVIDER
_H_ | 124 #endif // COMPONENTS_NTP_SNIPPETS_OFFLINE_PAGES_RECENT_TAB_SUGGESTIONS_PROVIDER
_H_ |
| OLD | NEW |