| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 // An implementation of WebURLLoader in terms of ResourceLoaderBridge. | 5 // An implementation of WebURLLoader in terms of ResourceLoaderBridge. |
| 6 | 6 |
| 7 #include "content/child/web_url_loader_impl.h" | 7 #include "content/child/web_url_loader_impl.h" |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/files/file_path.h" | 10 #include "base/files/file_path.h" |
| (...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 344 load_flags |= net::LOAD_PREFERRING_CACHE; | 344 load_flags |= net::LOAD_PREFERRING_CACHE; |
| 345 break; | 345 break; |
| 346 case WebURLRequest::ReturnCacheDataDontLoad: | 346 case WebURLRequest::ReturnCacheDataDontLoad: |
| 347 load_flags |= net::LOAD_ONLY_FROM_CACHE; | 347 load_flags |= net::LOAD_ONLY_FROM_CACHE; |
| 348 break; | 348 break; |
| 349 case WebURLRequest::UseProtocolCachePolicy: | 349 case WebURLRequest::UseProtocolCachePolicy: |
| 350 break; | 350 break; |
| 351 default: | 351 default: |
| 352 NOTREACHED(); | 352 NOTREACHED(); |
| 353 } | 353 } |
| 354 if (request.skipServiceWorker()) |
| 355 load_flags |= net::LOAD_SKIP_SERVICE_WORKER; |
| 354 | 356 |
| 355 if (request.reportUploadProgress()) | 357 if (request.reportUploadProgress()) |
| 356 load_flags |= net::LOAD_ENABLE_UPLOAD_PROGRESS; | 358 load_flags |= net::LOAD_ENABLE_UPLOAD_PROGRESS; |
| 357 if (request.reportRawHeaders()) | 359 if (request.reportRawHeaders()) |
| 358 load_flags |= net::LOAD_REPORT_RAW_HEADERS; | 360 load_flags |= net::LOAD_REPORT_RAW_HEADERS; |
| 359 | 361 |
| 360 if (!request.allowStoredCredentials()) { | 362 if (!request.allowStoredCredentials()) { |
| 361 load_flags |= net::LOAD_DO_NOT_SAVE_COOKIES; | 363 load_flags |= net::LOAD_DO_NOT_SAVE_COOKIES; |
| 362 load_flags |= net::LOAD_DO_NOT_SEND_COOKIES; | 364 load_flags |= net::LOAD_DO_NOT_SEND_COOKIES; |
| 363 } | 365 } |
| (...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 886 int intra_priority_value) { | 888 int intra_priority_value) { |
| 887 context_->DidChangePriority(new_priority, intra_priority_value); | 889 context_->DidChangePriority(new_priority, intra_priority_value); |
| 888 } | 890 } |
| 889 | 891 |
| 890 bool WebURLLoaderImpl::attachThreadedDataReceiver( | 892 bool WebURLLoaderImpl::attachThreadedDataReceiver( |
| 891 blink::WebThreadedDataReceiver* threaded_data_receiver) { | 893 blink::WebThreadedDataReceiver* threaded_data_receiver) { |
| 892 return context_->AttachThreadedDataReceiver(threaded_data_receiver); | 894 return context_->AttachThreadedDataReceiver(threaded_data_receiver); |
| 893 } | 895 } |
| 894 | 896 |
| 895 } // namespace content | 897 } // namespace content |
| OLD | NEW |