OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/service/net/service_url_request_context.h" | 5 #include "chrome/service/net/service_url_request_context.h" |
6 | 6 |
7 #if defined(OS_POSIX) && !defined(OS_MACOSX) | 7 #if defined(OS_POSIX) && !defined(OS_MACOSX) |
8 #include <sys/utsname.h> | 8 #include <sys/utsname.h> |
9 #endif | 9 #endif |
10 | 10 |
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
128 net::HttpNetworkLayer::CreateFactory(host_resolver_, | 128 net::HttpNetworkLayer::CreateFactory(host_resolver_, |
129 cert_verifier_, | 129 cert_verifier_, |
130 dnsrr_resolver_, | 130 dnsrr_resolver_, |
131 NULL /* dns_cert_checker */, | 131 NULL /* dns_cert_checker */, |
132 NULL /* ssl_host_info_factory */, | 132 NULL /* ssl_host_info_factory */, |
133 proxy_service_, | 133 proxy_service_, |
134 ssl_config_service_, | 134 ssl_config_service_, |
135 http_auth_handler_factory_, | 135 http_auth_handler_factory_, |
136 NULL /* network_delegate */, | 136 NULL /* network_delegate */, |
137 NULL /* net_log */), | 137 NULL /* net_log */), |
138 NULL /* net_log */, | |
139 net::HttpCache::DefaultBackend::InMemory(0)); | 138 net::HttpCache::DefaultBackend::InMemory(0)); |
140 // In-memory cookie store. | 139 // In-memory cookie store. |
141 cookie_store_ = new net::CookieMonster(NULL, NULL); | 140 cookie_store_ = new net::CookieMonster(NULL, NULL); |
142 accept_language_ = "en-us,fr"; | 141 accept_language_ = "en-us,fr"; |
143 accept_charset_ = "iso-8859-1,*,utf-8"; | 142 accept_charset_ = "iso-8859-1,*,utf-8"; |
144 } | 143 } |
145 | 144 |
146 const std::string& ServiceURLRequestContext::GetUserAgent( | 145 const std::string& ServiceURLRequestContext::GetUserAgent( |
147 const GURL& url) const { | 146 const GURL& url) const { |
148 // If the user agent is set explicitly return that, otherwise call the | 147 // If the user agent is set explicitly return that, otherwise call the |
(...skipping 23 matching lines...) Expand all Loading... |
172 url_request_context_ = new ServiceURLRequestContext(user_agent_); | 171 url_request_context_ = new ServiceURLRequestContext(user_agent_); |
173 return url_request_context_; | 172 return url_request_context_; |
174 } | 173 } |
175 | 174 |
176 scoped_refptr<base::MessageLoopProxy> | 175 scoped_refptr<base::MessageLoopProxy> |
177 ServiceURLRequestContextGetter::GetIOMessageLoopProxy() const { | 176 ServiceURLRequestContextGetter::GetIOMessageLoopProxy() const { |
178 return io_message_loop_proxy_; | 177 return io_message_loop_proxy_; |
179 } | 178 } |
180 | 179 |
181 ServiceURLRequestContextGetter::~ServiceURLRequestContextGetter() {} | 180 ServiceURLRequestContextGetter::~ServiceURLRequestContextGetter() {} |
OLD | NEW |