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 #include "content/child/web_url_loader_impl.h" | 5 #include "content/child/web_url_loader_impl.h" |
6 | 6 |
7 #include <stdint.h> | 7 #include <stdint.h> |
8 | 8 |
9 #include <algorithm> | 9 #include <algorithm> |
10 #include <memory> | 10 #include <memory> |
(...skipping 1150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1161 context_->SetDefersLoading(value); | 1161 context_->SetDefersLoading(value); |
1162 } | 1162 } |
1163 | 1163 |
1164 void WebURLLoaderImpl::didChangePriority(WebURLRequest::Priority new_priority, | 1164 void WebURLLoaderImpl::didChangePriority(WebURLRequest::Priority new_priority, |
1165 int intra_priority_value) { | 1165 int intra_priority_value) { |
1166 context_->DidChangePriority(new_priority, intra_priority_value); | 1166 context_->DidChangePriority(new_priority, intra_priority_value); |
1167 } | 1167 } |
1168 | 1168 |
1169 void WebURLLoaderImpl::setLoadingTaskRunner( | 1169 void WebURLLoaderImpl::setLoadingTaskRunner( |
1170 blink::WebTaskRunner* loading_task_runner) { | 1170 blink::WebTaskRunner* loading_task_runner) { |
1171 context_->SetTaskRunner(loading_task_runner->taskRunner()); | 1171 context_->SetTaskRunner(loading_task_runner->toSingleThreadTaskRunner()); |
1172 } | 1172 } |
1173 | 1173 |
1174 // This function is implemented here because it uses net functions. it is | 1174 // This function is implemented here because it uses net functions. it is |
1175 // tested in | 1175 // tested in |
1176 // third_party/WebKit/Source/core/fetch/MultipartImageResourceParserTest.cpp. | 1176 // third_party/WebKit/Source/core/fetch/MultipartImageResourceParserTest.cpp. |
1177 bool WebURLLoaderImpl::ParseMultipartHeadersFromBody( | 1177 bool WebURLLoaderImpl::ParseMultipartHeadersFromBody( |
1178 const char* bytes, | 1178 const char* bytes, |
1179 size_t size, | 1179 size_t size, |
1180 blink::WebURLResponse* response, | 1180 blink::WebURLResponse* response, |
1181 size_t* end) { | 1181 size_t* end) { |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1213 response->clearHTTPHeaderField(webStringName); | 1213 response->clearHTTPHeaderField(webStringName); |
1214 while (response_headers->EnumerateHeader(&iterator, name, &value)) { | 1214 while (response_headers->EnumerateHeader(&iterator, name, &value)) { |
1215 response->addHTTPHeaderField(webStringName, | 1215 response->addHTTPHeaderField(webStringName, |
1216 WebString::fromLatin1(value)); | 1216 WebString::fromLatin1(value)); |
1217 } | 1217 } |
1218 } | 1218 } |
1219 return true; | 1219 return true; |
1220 } | 1220 } |
1221 | 1221 |
1222 } // namespace content | 1222 } // namespace content |
OLD | NEW |