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

Unified Diff: content/browser/download/download_request_core.h

Issue 2874013002: Add GetWakeLockWithoutContext() in WakeLockContextProvider mojo interface. (Closed)
Patch Set: Addressed Colin's comments. 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: content/browser/download/download_request_core.h
diff --git a/content/browser/download/download_request_core.h b/content/browser/download/download_request_core.h
index ff254839e99e56282a8812f5e25291cf1b5a1e0a..dae9398659fcc28bb1a729a0c72923ffe419f890 100644
--- a/content/browser/download/download_request_core.h
+++ b/content/browser/download/download_request_core.h
@@ -18,10 +18,7 @@
#include "content/public/browser/download_interrupt_reasons.h"
#include "content/public/browser/download_save_info.h"
#include "content/public/browser/download_url_parameters.h"
-
-namespace device {
-class PowerSaveBlocker;
-} // namespace device
+#include "device/wake_lock/public/interfaces/wake_lock_service.mojom.h"
namespace net {
class HttpResponseHeaders;
@@ -145,10 +142,10 @@ class CONTENT_EXPORT DownloadRequestCore
scoped_refptr<net::IOBuffer> read_buffer_; // From URLRequest.
std::unique_ptr<ByteStreamWriter> stream_writer_; // To rest of system.
- // Keeps the system from sleeping while this is alive. If the
- // system enters power saving mode while a request is alive, it can cause the
- // request to fail and the associated download will be interrupted.
- std::unique_ptr<device::PowerSaveBlocker> power_save_blocker_;
+ // Used to keep the system from sleeping while a download is ongoing. If the
+ // system enters power saving mode while a URLRequest is alive, it can cause
+ // URLRequest to fail and the associated download will be interrupted.
+ device::mojom::WakeLockServicePtr wake_lock_;
// The following are used to collect stats.
base::TimeTicks download_start_time_;
« no previous file with comments | « no previous file | content/browser/download/download_request_core.cc » ('j') | content/browser/download/download_request_core.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698