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/profiles/profile_io_data.h" | 5 #include "chrome/browser/profiles/profile_io_data.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 1003 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1014 scoped_timer("Startup.SlowStartupProfileIODataInit"); | 1014 scoped_timer("Startup.SlowStartupProfileIODataInit"); |
1015 | 1015 |
1016 // TODO(jhawkins): Remove once crbug.com/102004 is fixed. | 1016 // TODO(jhawkins): Remove once crbug.com/102004 is fixed. |
1017 CHECK(initialized_on_UI_thread_); | 1017 CHECK(initialized_on_UI_thread_); |
1018 | 1018 |
1019 // TODO(jhawkins): Return to DCHECK once crbug.com/102004 is fixed. | 1019 // TODO(jhawkins): Return to DCHECK once crbug.com/102004 is fixed. |
1020 CHECK(profile_params_.get()); | 1020 CHECK(profile_params_.get()); |
1021 | 1021 |
1022 IOThread* const io_thread = profile_params_->io_thread; | 1022 IOThread* const io_thread = profile_params_->io_thread; |
1023 IOThread::Globals* const io_thread_globals = io_thread->globals(); | 1023 IOThread::Globals* const io_thread_globals = io_thread->globals(); |
1024 const CommandLine& command_line = *CommandLine::ForCurrentProcess(); | 1024 const base::CommandLine& command_line = |
| 1025 *base::CommandLine::ForCurrentProcess(); |
1025 | 1026 |
1026 // TODO(vadimt): Remove ScopedTracker below once crbug.com/436671 is fixed. | 1027 // TODO(vadimt): Remove ScopedTracker below once crbug.com/436671 is fixed. |
1027 tracked_objects::ScopedTracker tracking_profile1( | 1028 tracked_objects::ScopedTracker tracking_profile1( |
1028 FROM_HERE_WITH_EXPLICIT_FUNCTION("436671 ProfileIOData::Init1")); | 1029 FROM_HERE_WITH_EXPLICIT_FUNCTION("436671 ProfileIOData::Init1")); |
1029 | 1030 |
1030 // Create the common request contexts. | 1031 // Create the common request contexts. |
1031 main_request_context_.reset(new net::URLRequestContext()); | 1032 main_request_context_.reset(new net::URLRequestContext()); |
1032 extensions_request_context_.reset(new net::URLRequestContext()); | 1033 extensions_request_context_.reset(new net::URLRequestContext()); |
1033 | 1034 |
1034 // TODO(vadimt): Remove ScopedTracker below once crbug.com/436671 is fixed. | 1035 // TODO(vadimt): Remove ScopedTracker below once crbug.com/436671 is fixed. |
(...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1340 void ProfileIOData::SetCookieSettingsForTesting( | 1341 void ProfileIOData::SetCookieSettingsForTesting( |
1341 CookieSettings* cookie_settings) { | 1342 CookieSettings* cookie_settings) { |
1342 DCHECK(!cookie_settings_.get()); | 1343 DCHECK(!cookie_settings_.get()); |
1343 cookie_settings_ = cookie_settings; | 1344 cookie_settings_ = cookie_settings; |
1344 } | 1345 } |
1345 | 1346 |
1346 void ProfileIOData::set_signin_names_for_testing( | 1347 void ProfileIOData::set_signin_names_for_testing( |
1347 SigninNamesOnIOThread* signin_names) { | 1348 SigninNamesOnIOThread* signin_names) { |
1348 signin_names_.reset(signin_names); | 1349 signin_names_.reset(signin_names); |
1349 } | 1350 } |
OLD | NEW |