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

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

Issue 2491613004: Make base::Timer sequence-friendly. (Closed)
Patch Set: add back commented out DCHECK in Stop() 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
« no previous file with comments | « build/sanitizers/tsan_suppressions.cc ('k') | content/browser/loader/upload_progress_tracker.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/loader/upload_progress_tracker.h
diff --git a/content/browser/loader/upload_progress_tracker.h b/content/browser/loader/upload_progress_tracker.h
index 6840f5a60bc174c5a01e547df2539b9878a74970..236ced27a5fc74e96dd5c3e6602f1e5aef1d7342 100644
--- a/content/browser/loader/upload_progress_tracker.h
+++ b/content/browser/loader/upload_progress_tracker.h
@@ -10,17 +10,13 @@
#include "base/callback.h"
#include "base/macros.h"
#include "base/memory/ref_counted.h"
-#include "base/single_thread_task_runner.h"
-#include "base/threading/thread_task_runner_handle.h"
+#include "base/sequenced_task_runner.h"
+#include "base/threading/sequenced_task_runner_handle.h"
#include "base/time/time.h"
#include "base/timer/timer.h"
#include "content/common/content_export.h"
#include "net/base/upload_progress.h"
-namespace base {
-class SingleThreadTaskRunner;
-}
-
namespace tracked_objects {
class Location;
}
@@ -41,13 +37,15 @@ class CONTENT_EXPORT UploadProgressTracker {
UploadProgressTracker(const tracked_objects::Location& location,
UploadProgressReportCallback report_progress,
net::URLRequest* request,
- scoped_refptr<base::SingleThreadTaskRunner>
- task_runner = base::ThreadTaskRunnerHandle::Get());
+ scoped_refptr<base::SequencedTaskRunner> task_runner =
+ base::SequencedTaskRunnerHandle::Get());
~UploadProgressTracker();
void OnAckReceived();
void OnUploadCompleted();
+ static base::TimeDelta GetUploadProgressIntervalForTesting();
+
private:
// Overridden by tests to use a fake time and progress.
virtual base::TimeTicks GetCurrentTime() const;
« no previous file with comments | « build/sanitizers/tsan_suppressions.cc ('k') | content/browser/loader/upload_progress_tracker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698