Index: components/offline_pages/offline_page_model.h |
diff --git a/components/offline_pages/offline_page_model.h b/components/offline_pages/offline_page_model.h |
index ab08104a4b3f43ad96db091278a3e04409c83ebf..aa23d95b72330d3f4cc4f16d8549d9173296781b 100644 |
--- a/components/offline_pages/offline_page_model.h |
+++ b/components/offline_pages/offline_page_model.h |
@@ -167,7 +167,8 @@ class OfflinePageModel : public KeyedService, |
void DeletePagesByBookmarkId(const std::vector<int64>& bookmark_ids, |
const DeletePageCallback& callback); |
- void UndeletePage(int64 bookmark_id, const DeletePageCallback& callback); |
+ // Remove all saved files and clear the store. |
+ void ClearAll(const base::Closure& callback); |
fgorski
2015/10/23 20:55:03
DeleteAllPages -- to be consistent with the naming
jianli
2015/10/26 21:42:44
I think semantically ClearAll is a bit different f
fgorski
2015/10/27 20:13:09
Acknowledged.
|
// Gets all available offline pages. Requires that the model is loaded. |
const std::vector<OfflinePageItem> GetAllPages() const; |
@@ -263,6 +264,17 @@ class OfflinePageModel : public KeyedService, |
const std::vector<int64>& bookmark_ids, |
OfflinePageModel::DeletePageResult result); |
+ // Steps for clearing all. |
+ void OnRemoveAllFilesDoneForClearAll(const base::Closure& callback, |
+ DeletePageResult result); |
+ void OnResetStoreDoneForClearAll(const base::Closure& callback, bool success); |
+ void OnReloadStoreDoneForClearAll( |
+ const base::Closure& callback, |
+ bool success, |
+ const std::vector<OfflinePageItem>& offline_pages); |
+ |
+ void CacheLoadedData(const std::vector<OfflinePageItem>& offline_pages); |
+ |
// Persistent store for offline page metadata. |
scoped_ptr<OfflinePageMetadataStore> store_; |