Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(515)

Unified Diff: components/offline_pages/offline_page_model_impl.h

Issue 2142703002: [Offline Pages] Showing expired pages in internal page. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix tests. Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/offline_pages/offline_page_model.h ('k') | components/offline_pages/offline_page_model_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/offline_pages/offline_page_model_impl.h
diff --git a/components/offline_pages/offline_page_model_impl.h b/components/offline_pages/offline_page_model_impl.h
index 1efb687e3ad325976d84351883ad18f7423d30e0..b93a227ebf40a5f09029fd8ffdbd3921eae29da0 100644
--- a/components/offline_pages/offline_page_model_impl.h
+++ b/components/offline_pages/offline_page_model_impl.h
@@ -81,6 +81,8 @@ class OfflinePageModelImpl : public OfflinePageModel, public KeyedService {
const std::set<GURL>& urls,
const CheckPagesExistOfflineCallback& callback) override;
void GetAllPages(const MultipleOfflinePageItemCallback& callback) override;
+ void GetAllPagesWithExpired(
+ const MultipleOfflinePageItemCallback& callback) override;
void GetOfflineIdsForClientId(
const ClientId& client_id,
const MultipleOfflineIdCallback& callback) override;
@@ -127,12 +129,18 @@ class OfflinePageModelImpl : public OfflinePageModel, public KeyedService {
private:
FRIEND_TEST_ALL_PREFIXES(OfflinePageModelImplTest, MarkPageForDeletion);
+ enum class GetAllPageMode {
+ ALL, // Get all active page entries.
+ ALL_WITH_EXPIRED, // Get all pages entries including expired ones.
+ };
+
typedef ScopedVector<OfflinePageArchiver> PendingArchivers;
// Callback for ensuring archive directory is created.
void OnEnsureArchivesDirCreatedDone(const base::TimeTicks& start_time);
void GetAllPagesAfterLoadDone(
+ GetAllPageMode mode,
const MultipleOfflinePageItemCallback& callback) const;
void CheckPagesExistOfflineAfterLoadDone(
const std::set<GURL>& urls,
« no previous file with comments | « components/offline_pages/offline_page_model.h ('k') | components/offline_pages/offline_page_model_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698