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

Unified Diff: components/offline_pages/core/background/offliner_stub.h

Issue 2857063002: Add a way to send the resource percentage signal to the RC. (Closed)
Patch Set: CR Feedback per Dimich, BMcQuade, and CSHarrison Created 3 years, 7 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
Index: components/offline_pages/core/background/offliner_stub.h
diff --git a/components/offline_pages/core/background/offliner_stub.h b/components/offline_pages/core/background/offliner_stub.h
index d6ddc2486bd70b8db6d7e1883aca550713305580..3a965b00042712d2882bf6773287a3e7c6eaa73c 100644
--- a/components/offline_pages/core/background/offliner_stub.h
+++ b/components/offline_pages/core/background/offliner_stub.h
@@ -27,6 +27,10 @@ class OfflinerStub : public Offliner {
bool HandleTimeout(int64_t request_id) override;
+ void ObserveResourceTracking(const ResourceDataType type,
+ int64_t started_count,
+ int64_t completed_count) override;
+
void disable_loading() { disable_loading_ = true; }
void enable_callback(bool enable) { enable_callback_ = enable; }
@@ -37,6 +41,10 @@ class OfflinerStub : public Offliner {
void enable_snapshot_on_last_retry() { snapshot_on_last_retry_ = true; }
+ void GetResourcePercentageCounts(const ResourceDataType type,
+ int64_t* started,
+ int64_t* completed);
+
private:
base::Closure completion_callback_;
std::unique_ptr<SavePageRequest> pending_request_;
@@ -44,6 +52,8 @@ class OfflinerStub : public Offliner {
bool enable_callback_;
bool cancel_called_;
bool snapshot_on_last_retry_;
+ int64_t started_count_;
+ int64_t completed_count_;
};
} // namespace offline_pages

Powered by Google App Engine
This is Rietveld 408576698