Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(46)

Side by Side Diff: ios/chrome/browser/ios_chrome_io_thread.mm

Issue 2705293014: Created web::UserAgentType. (Closed)
Patch Set: self review Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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
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
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 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698