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 348 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
359 user->username_hash(), | 359 user->username_hash(), |
360 profile->GetPath(), | 360 profile->GetPath(), |
361 is_primary_user)); | 361 is_primary_user)); |
362 } | 362 } |
363 } | 363 } |
364 if (params->username_hash.empty()) | 364 if (params->username_hash.empty()) |
365 LOG(WARNING) << "no username_hash"; | 365 LOG(WARNING) << "no username_hash"; |
366 #endif | 366 #endif |
367 | 367 |
368 params->profile = profile; | 368 params->profile = profile; |
| 369 params->prerender_tracker = g_browser_process->prerender_tracker(); |
369 profile_params_.reset(params.release()); | 370 profile_params_.reset(params.release()); |
370 | 371 |
371 ChromeNetworkDelegate::InitializePrefsOnUIThread( | 372 ChromeNetworkDelegate::InitializePrefsOnUIThread( |
372 &enable_referrers_, | 373 &enable_referrers_, |
373 &enable_do_not_track_, | 374 &enable_do_not_track_, |
374 &force_safesearch_, | 375 &force_safesearch_, |
375 pref_service); | 376 pref_service); |
376 | 377 |
377 scoped_refptr<base::MessageLoopProxy> io_message_loop_proxy = | 378 scoped_refptr<base::MessageLoopProxy> io_message_loop_proxy = |
378 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::IO); | 379 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::IO); |
(...skipping 562 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
941 network_delegate->set_extension_info_map( | 942 network_delegate->set_extension_info_map( |
942 profile_params_->extension_info_map.get()); | 943 profile_params_->extension_info_map.get()); |
943 #if defined(ENABLE_CONFIGURATION_POLICY) | 944 #if defined(ENABLE_CONFIGURATION_POLICY) |
944 network_delegate->set_url_blacklist_manager(url_blacklist_manager_.get()); | 945 network_delegate->set_url_blacklist_manager(url_blacklist_manager_.get()); |
945 #endif | 946 #endif |
946 network_delegate->set_profile(profile_params_->profile); | 947 network_delegate->set_profile(profile_params_->profile); |
947 network_delegate->set_profile_path(profile_params_->path); | 948 network_delegate->set_profile_path(profile_params_->path); |
948 network_delegate->set_cookie_settings(profile_params_->cookie_settings.get()); | 949 network_delegate->set_cookie_settings(profile_params_->cookie_settings.get()); |
949 network_delegate->set_enable_do_not_track(&enable_do_not_track_); | 950 network_delegate->set_enable_do_not_track(&enable_do_not_track_); |
950 network_delegate->set_force_google_safe_search(&force_safesearch_); | 951 network_delegate->set_force_google_safe_search(&force_safesearch_); |
| 952 network_delegate->set_prerender_tracker(profile_params_->prerender_tracker); |
951 network_delegate_.reset(network_delegate); | 953 network_delegate_.reset(network_delegate); |
952 | 954 |
953 fraudulent_certificate_reporter_.reset( | 955 fraudulent_certificate_reporter_.reset( |
954 new chrome_browser_net::ChromeFraudulentCertificateReporter( | 956 new chrome_browser_net::ChromeFraudulentCertificateReporter( |
955 main_request_context_.get())); | 957 main_request_context_.get())); |
956 | 958 |
957 // NOTE: Proxy service uses the default io thread network delegate, not the | 959 // NOTE: Proxy service uses the default io thread network delegate, not the |
958 // delegate just created. | 960 // delegate just created. |
959 proxy_service_.reset( | 961 proxy_service_.reset( |
960 ProxyServiceFactory::CreateProxyService( | 962 ProxyServiceFactory::CreateProxyService( |
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1171 void ProfileIOData::SetCookieSettingsForTesting( | 1173 void ProfileIOData::SetCookieSettingsForTesting( |
1172 CookieSettings* cookie_settings) { | 1174 CookieSettings* cookie_settings) { |
1173 DCHECK(!cookie_settings_.get()); | 1175 DCHECK(!cookie_settings_.get()); |
1174 cookie_settings_ = cookie_settings; | 1176 cookie_settings_ = cookie_settings; |
1175 } | 1177 } |
1176 | 1178 |
1177 void ProfileIOData::set_signin_names_for_testing( | 1179 void ProfileIOData::set_signin_names_for_testing( |
1178 SigninNamesOnIOThread* signin_names) { | 1180 SigninNamesOnIOThread* signin_names) { |
1179 signin_names_.reset(signin_names); | 1181 signin_names_.reset(signin_names); |
1180 } | 1182 } |
OLD | NEW |