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

Side by Side Diff: net/url_request/url_request_job.cc

Issue 8523021: Send WM_DEVICECHANGE message through SystemMonitor (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: rebase Created 9 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « content/content_browser.gypi ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/url_request/url_request_job.h" 5 #include "net/url_request/url_request_job.h"
6 6
7 #include "base/compiler_specific.h" 7 #include "base/compiler_specific.h"
8 #include "base/message_loop.h" 8 #include "base/message_loop.h"
9 #include "base/string_number_conversions.h" 9 #include "base/string_number_conversions.h"
10 #include "base/string_util.h" 10 #include "base/string_util.h"
(...skipping 16 matching lines...) Expand all
27 postfilter_bytes_read_(0), 27 postfilter_bytes_read_(0),
28 filter_input_byte_count_(0), 28 filter_input_byte_count_(0),
29 filter_needs_more_output_space_(false), 29 filter_needs_more_output_space_(false),
30 filtered_read_buffer_len_(0), 30 filtered_read_buffer_len_(0),
31 has_handled_response_(false), 31 has_handled_response_(false),
32 expected_content_size_(-1), 32 expected_content_size_(-1),
33 deferred_redirect_status_code_(-1), 33 deferred_redirect_status_code_(-1),
34 ALLOW_THIS_IN_INITIALIZER_LIST(method_factory_(this)) { 34 ALLOW_THIS_IN_INITIALIZER_LIST(method_factory_(this)) {
35 base::SystemMonitor* system_monitor = base::SystemMonitor::Get(); 35 base::SystemMonitor* system_monitor = base::SystemMonitor::Get();
36 if (system_monitor) 36 if (system_monitor)
37 base::SystemMonitor::Get()->AddObserver(this); 37 base::SystemMonitor::Get()->AddPowerObserver(this);
38 } 38 }
39 39
40 void URLRequestJob::SetUpload(UploadData* upload) { 40 void URLRequestJob::SetUpload(UploadData* upload) {
41 } 41 }
42 42
43 void URLRequestJob::SetExtraRequestHeaders(const HttpRequestHeaders& headers) { 43 void URLRequestJob::SetExtraRequestHeaders(const HttpRequestHeaders& headers) {
44 } 44 }
45 45
46 void URLRequestJob::Kill() { 46 void URLRequestJob::Kill() {
47 method_factory_.RevokeAll(); 47 method_factory_.RevokeAll();
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 void URLRequestJob::OnSuspend() { 212 void URLRequestJob::OnSuspend() {
213 Kill(); 213 Kill();
214 } 214 }
215 215
216 void URLRequestJob::NotifyURLRequestDestroyed() { 216 void URLRequestJob::NotifyURLRequestDestroyed() {
217 } 217 }
218 218
219 URLRequestJob::~URLRequestJob() { 219 URLRequestJob::~URLRequestJob() {
220 base::SystemMonitor* system_monitor = base::SystemMonitor::Get(); 220 base::SystemMonitor* system_monitor = base::SystemMonitor::Get();
221 if (system_monitor) 221 if (system_monitor)
222 base::SystemMonitor::Get()->RemoveObserver(this); 222 base::SystemMonitor::Get()->RemovePowerObserver(this);
223 } 223 }
224 224
225 void URLRequestJob::NotifyCertificateRequested( 225 void URLRequestJob::NotifyCertificateRequested(
226 SSLCertRequestInfo* cert_request_info) { 226 SSLCertRequestInfo* cert_request_info) {
227 if (!request_) 227 if (!request_)
228 return; // The request was destroyed, so there is no more work to do. 228 return; // The request was destroyed, so there is no more work to do.
229 229
230 request_->NotifyCertificateRequested(cert_request_info); 230 request_->NotifyCertificateRequested(cert_request_info);
231 } 231 }
232 232
(...skipping 465 matching lines...) Expand 10 before | Expand all | Expand 10 after
698 } 698 }
699 699
700 bool URLRequestJob::FilterHasData() { 700 bool URLRequestJob::FilterHasData() {
701 return filter_.get() && filter_->stream_data_len(); 701 return filter_.get() && filter_->stream_data_len();
702 } 702 }
703 703
704 void URLRequestJob::UpdatePacketReadTimes() { 704 void URLRequestJob::UpdatePacketReadTimes() {
705 } 705 }
706 706
707 } // namespace net 707 } // namespace net
OLDNEW
« no previous file with comments | « content/content_browser.gypi ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698