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

Unified Diff: content/browser/loader/async_resource_handler.h

Issue 2546653003: Factor out upload progress handling from AsyncResourceHandler (Closed)
Patch Set: . Created 4 years 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: content/browser/loader/async_resource_handler.h
diff --git a/content/browser/loader/async_resource_handler.h b/content/browser/loader/async_resource_handler.h
index 1279d506be3529f17b4208d80e247f5f5e4d2023..a02a57c5b4152a81c4de3062c7bdf139ab80d4c6 100644
--- a/content/browser/loader/async_resource_handler.h
+++ b/content/browser/loader/async_resource_handler.h
@@ -25,6 +25,7 @@ class URLRequest;
namespace content {
class ResourceBuffer;
class ResourceDispatcherHostImpl;
+class UploadProgressTracker;
// Used to complete an asynchronous resource request in response to resource
// load events from the resource dispatcher host.
@@ -59,8 +60,6 @@ class CONTENT_EXPORT AsyncResourceHandler : public ResourceHandler,
void OnDataReceivedACK(int request_id);
void OnUploadProgressACK(int request_id);
- void ReportUploadProgress();
-
bool EnsureResourceBufferIsInitialized();
void ResumeIfDeferred();
void OnDefer();
@@ -89,10 +88,7 @@ class CONTENT_EXPORT AsyncResourceHandler : public ResourceHandler,
std::unique_ptr<InliningHelper> inlining_helper_;
base::TimeTicks response_started_ticks_;
- uint64_t last_upload_position_;
- bool waiting_for_upload_progress_ack_;
- base::TimeTicks last_upload_ticks_;
- base::RepeatingTimer progress_timer_;
+ std::unique_ptr<UploadProgressTracker> upload_progress_tracker_;
int64_t reported_transfer_size_;

Powered by Google App Engine
This is Rietveld 408576698