| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "ios/chrome/browser/ios_chrome_io_thread.h" | 5 #include "ios/chrome/browser/ios_chrome_io_thread.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 370 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 381 CreateDefaultAuthHandlerFactory(); | 381 CreateDefaultAuthHandlerFactory(); |
| 382 globals_->http_server_properties.reset(new net::HttpServerPropertiesImpl()); | 382 globals_->http_server_properties.reset(new net::HttpServerPropertiesImpl()); |
| 383 // In-memory cookie store. | 383 // In-memory cookie store. |
| 384 globals_->system_cookie_store.reset(new net::CookieMonster(nullptr, nullptr)); | 384 globals_->system_cookie_store.reset(new net::CookieMonster(nullptr, nullptr)); |
| 385 // In-memory channel ID store. | 385 // In-memory channel ID store. |
| 386 globals_->system_channel_id_service.reset( | 386 globals_->system_channel_id_service.reset( |
| 387 new net::ChannelIDService(new net::DefaultChannelIDStore(nullptr))); | 387 new net::ChannelIDService(new net::DefaultChannelIDStore(nullptr))); |
| 388 globals_->system_cookie_store->SetChannelIDServiceID( | 388 globals_->system_cookie_store->SetChannelIDServiceID( |
| 389 globals_->system_channel_id_service->GetUniqueID()); | 389 globals_->system_channel_id_service->GetUniqueID()); |
| 390 globals_->http_user_agent_settings.reset(new net::StaticHttpUserAgentSettings( | 390 globals_->http_user_agent_settings.reset(new net::StaticHttpUserAgentSettings( |
| 391 std::string(), web::GetWebClient()->GetUserAgent(false))); | 391 std::string(), |
| 392 web::GetWebClient()->GetUserAgent(web::UserAgentType::MOBILE))); |
| 392 if (command_line.HasSwitch(switches::kIOSTestingFixedHttpPort)) { | 393 if (command_line.HasSwitch(switches::kIOSTestingFixedHttpPort)) { |
| 393 params_.testing_fixed_http_port = | 394 params_.testing_fixed_http_port = |
| 394 GetSwitchValueAsInt(command_line, switches::kIOSTestingFixedHttpPort); | 395 GetSwitchValueAsInt(command_line, switches::kIOSTestingFixedHttpPort); |
| 395 } | 396 } |
| 396 if (command_line.HasSwitch(switches::kIOSTestingFixedHttpsPort)) { | 397 if (command_line.HasSwitch(switches::kIOSTestingFixedHttpsPort)) { |
| 397 params_.testing_fixed_https_port = | 398 params_.testing_fixed_https_port = |
| 398 GetSwitchValueAsInt(command_line, switches::kIOSTestingFixedHttpsPort); | 399 GetSwitchValueAsInt(command_line, switches::kIOSTestingFixedHttpsPort); |
| 399 } | 400 } |
| 400 | 401 |
| 401 params_.ignore_certificate_errors = false; | 402 params_.ignore_certificate_errors = false; |
| (...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 566 | 567 |
| 567 globals->system_http_network_session.reset( | 568 globals->system_http_network_session.reset( |
| 568 new net::HttpNetworkSession(system_params)); | 569 new net::HttpNetworkSession(system_params)); |
| 569 globals->system_http_transaction_factory.reset( | 570 globals->system_http_transaction_factory.reset( |
| 570 new net::HttpNetworkLayer(globals->system_http_network_session.get())); | 571 new net::HttpNetworkLayer(globals->system_http_network_session.get())); |
| 571 context->set_http_transaction_factory( | 572 context->set_http_transaction_factory( |
| 572 globals->system_http_transaction_factory.get()); | 573 globals->system_http_transaction_factory.get()); |
| 573 | 574 |
| 574 return context; | 575 return context; |
| 575 } | 576 } |
| OLD | NEW |