OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "chrome/browser/policy/cloud/device_management_service.h" | 5 #include "chrome/browser/policy/cloud/device_management_service.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
214 public: | 214 public: |
215 explicit DeviceManagementRequestContext(net::URLRequestContext* base_context); | 215 explicit DeviceManagementRequestContext(net::URLRequestContext* base_context); |
216 virtual ~DeviceManagementRequestContext(); | 216 virtual ~DeviceManagementRequestContext(); |
217 | 217 |
218 private: | 218 private: |
219 BasicHttpUserAgentSettings basic_http_user_agent_settings_; | 219 BasicHttpUserAgentSettings basic_http_user_agent_settings_; |
220 }; | 220 }; |
221 | 221 |
222 DeviceManagementRequestContext::DeviceManagementRequestContext( | 222 DeviceManagementRequestContext::DeviceManagementRequestContext( |
223 net::URLRequestContext* base_context) | 223 net::URLRequestContext* base_context) |
224 // Use sane Accept-Language and Accept-Charset values for our purposes. | 224 // Use sane Accept-Language value for our purposes. |
225 : basic_http_user_agent_settings_("*", "*") { | 225 : basic_http_user_agent_settings_("*") { |
226 // Share resolver, proxy service and ssl bits with the baseline context. This | 226 // Share resolver, proxy service and ssl bits with the baseline context. This |
227 // is important so we don't make redundant requests (e.g. when resolving proxy | 227 // is important so we don't make redundant requests (e.g. when resolving proxy |
228 // auto configuration). | 228 // auto configuration). |
229 set_net_log(base_context->net_log()); | 229 set_net_log(base_context->net_log()); |
230 set_host_resolver(base_context->host_resolver()); | 230 set_host_resolver(base_context->host_resolver()); |
231 set_proxy_service(base_context->proxy_service()); | 231 set_proxy_service(base_context->proxy_service()); |
232 set_ssl_config_service(base_context->ssl_config_service()); | 232 set_ssl_config_service(base_context->ssl_config_service()); |
233 | 233 |
234 // Share the http session. | 234 // Share the http session. |
235 set_http_transaction_factory( | 235 set_http_transaction_factory( |
(...skipping 405 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
641 } | 641 } |
642 } | 642 } |
643 | 643 |
644 const JobQueue::iterator elem = | 644 const JobQueue::iterator elem = |
645 std::find(queued_jobs_.begin(), queued_jobs_.end(), job); | 645 std::find(queued_jobs_.begin(), queued_jobs_.end(), job); |
646 if (elem != queued_jobs_.end()) | 646 if (elem != queued_jobs_.end()) |
647 queued_jobs_.erase(elem); | 647 queued_jobs_.erase(elem); |
648 } | 648 } |
649 | 649 |
650 } // namespace policy | 650 } // namespace policy |
OLD | NEW |