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

Unified Diff: update_attempter.h

Issue 3131022: AU: Update status to DOWNLOADING only after receiving some bytes from server. (Closed) Base URL: http://src.chromium.org/git/update_engine.git
Patch Set: review feedback Created 10 years, 4 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 | « download_action_unittest.cc ('k') | update_attempter.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: update_attempter.h
diff --git a/update_attempter.h b/update_attempter.h
index 19933219282184f31f15ee6710b7bfa0d8a9d20a..0f5d605a5c56c14c9c37ce6e7baaa5e37b73fb4f 100644
--- a/update_attempter.h
+++ b/update_attempter.h
@@ -87,7 +87,8 @@ class UpdateAttempter : public ActionProcessorDelegate,
// UPDATED_NEED_REBOOT. Returns true on sucess, false otherwise.
bool RebootIfNeeded();
- // DownloadActionDelegate method
+ // DownloadActionDelegate methods
+ void SetDownloadStatus(bool active);
void BytesReceived(uint64_t bytes_received, uint64_t total);
private:
@@ -152,6 +153,10 @@ class UpdateAttempter : public ActionProcessorDelegate,
// The process priority management timeout source.
GSource* manage_priority_source_;
+ // Set to true if an update download is active (and BytesReceived
+ // will be called), set to false otherwise.
+ bool download_active_;
+
// For status:
UpdateStatus status_;
double download_progress_;
« no previous file with comments | « download_action_unittest.cc ('k') | update_attempter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698