| Index: chrome/browser/profiles/profile_io_data.cc
|
| ===================================================================
|
| --- chrome/browser/profiles/profile_io_data.cc (revision 134639)
|
| +++ chrome/browser/profiles/profile_io_data.cc (working copy)
|
| @@ -160,6 +160,7 @@
|
|
|
| scoped_ptr<ProfileParams> params(new ProfileParams);
|
| params->path = profile->GetPath();
|
| + params->is_incognito = profile->IsOffTheRecord();
|
| params->clear_local_state_on_exit =
|
| pref_service->GetBoolean(prefs::kClearSiteDataOnExit);
|
|
|
| @@ -246,7 +247,8 @@
|
| ProfileIOData::AppRequestContext::~AppRequestContext() {}
|
|
|
| ProfileIOData::ProfileParams::ProfileParams()
|
| - : clear_local_state_on_exit(false),
|
| + : is_incognito(false),
|
| + clear_local_state_on_exit(false),
|
| io_thread(NULL),
|
| #if defined(ENABLE_NOTIFICATIONS)
|
| notification_service(NULL),
|
| @@ -260,8 +262,7 @@
|
| : initialized_(false),
|
| ALLOW_THIS_IN_INITIALIZER_LIST(
|
| resource_context_(new ResourceContext(this))),
|
| - initialized_on_UI_thread_(false),
|
| - is_incognito_(is_incognito) {
|
| + initialized_on_UI_thread_(false) {
|
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
|
| }
|
|
|
| @@ -464,7 +465,7 @@
|
| transport_security_persister_.reset(
|
| new TransportSecurityPersister(transport_security_state_.get(),
|
| profile_params_->path,
|
| - is_incognito()));
|
| + profile_params_->is_incognito));
|
|
|
| // NOTE(willchan): Keep these protocol handlers in sync with
|
| // ProfileIOData::IsHandledProtocol().
|
| @@ -476,7 +477,7 @@
|
| }
|
| bool set_protocol = job_factory_->SetProtocolHandler(
|
| chrome::kExtensionScheme,
|
| - CreateExtensionProtocolHandler(is_incognito(),
|
| + CreateExtensionProtocolHandler(profile_params_->is_incognito,
|
| profile_params_->extension_info_map));
|
| DCHECK(set_protocol);
|
| set_protocol = job_factory_->SetProtocolHandler(
|
| @@ -514,7 +515,7 @@
|
|
|
| void ProfileIOData::ApplyProfileParamsToContext(
|
| ChromeURLRequestContext* context) const {
|
| - context->set_is_incognito(is_incognito());
|
| + context->set_is_incognito(profile_params_->is_incognito);
|
| context->set_accept_language(profile_params_->accept_language);
|
| context->set_accept_charset(profile_params_->accept_charset);
|
| context->set_referrer_charset(profile_params_->referrer_charset);
|
| @@ -524,7 +525,6 @@
|
| void ProfileIOData::ShutdownOnUIThread() {
|
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
|
| enable_referrers_.Destroy();
|
| - enable_metrics_.Destroy();
|
| clear_local_state_on_exit_.Destroy();
|
| safe_browsing_enabled_.Destroy();
|
| session_startup_pref_.Destroy();
|
|
|