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_impl_io_data.h" | 5 #include "chrome/browser/profiles/profile_impl_io_data.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/metrics/field_trial.h" | 10 #include "base/metrics/field_trial.h" |
(...skipping 561 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
572 network_delegate(), | 572 network_delegate(), |
573 ftp_factory_.get()); | 573 ftp_factory_.get()); |
574 main_context->set_job_factory(main_job_factory_.get()); | 574 main_context->set_job_factory(main_job_factory_.get()); |
575 | 575 |
576 #if defined(ENABLE_EXTENSIONS) | 576 #if defined(ENABLE_EXTENSIONS) |
577 InitializeExtensionsRequestContext(profile_params); | 577 InitializeExtensionsRequestContext(profile_params); |
578 #endif | 578 #endif |
579 | 579 |
580 // Setup the SDCHManager for this profile. | 580 // Setup the SDCHManager for this profile. |
581 sdch_manager_.reset(new net::SdchManager); | 581 sdch_manager_.reset(new net::SdchManager); |
582 | |
583 scoped_refptr<net::URLRequestContextGetter> getter( | |
584 new net::TrivialURLRequestContextGetter( | |
585 main_context, | |
586 content::BrowserThread::GetMessageLoopProxyForThread( | |
587 content::BrowserThread::IO))); | |
588 | |
589 sdch_manager_->set_sdch_fetcher(scoped_ptr<net::SdchFetcher>( | 582 sdch_manager_->set_sdch_fetcher(scoped_ptr<net::SdchFetcher>( |
590 new net::SdchDictionaryFetcher(sdch_manager_.get(), getter)).Pass()); | 583 new net::SdchDictionaryFetcher(sdch_manager_.get(), |
591 | 584 main_context)).Pass()); |
592 main_context->set_sdch_manager(sdch_manager_.get()); | 585 main_context->set_sdch_manager(sdch_manager_.get()); |
593 | 586 |
594 // Create a media request context based on the main context, but using a | 587 // Create a media request context based on the main context, but using a |
595 // media cache. It shares the same job factory as the main context. | 588 // media cache. It shares the same job factory as the main context. |
596 StoragePartitionDescriptor details(profile_path_, false); | 589 StoragePartitionDescriptor details(profile_path_, false); |
597 media_request_context_.reset(InitializeMediaRequestContext(main_context, | 590 media_request_context_.reset(InitializeMediaRequestContext(main_context, |
598 details)); | 591 details)); |
599 | 592 |
600 if (domain_reliability_monitor_) { | 593 if (domain_reliability_monitor_) { |
601 domain_reliability_monitor_->Init( | 594 domain_reliability_monitor_->Init( |
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
834 const base::Closure& completion) { | 827 const base::Closure& completion) { |
835 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); | 828 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
836 DCHECK(initialized()); | 829 DCHECK(initialized()); |
837 | 830 |
838 DCHECK(transport_security_state()); | 831 DCHECK(transport_security_state()); |
839 // Completes synchronously. | 832 // Completes synchronously. |
840 transport_security_state()->DeleteAllDynamicDataSince(time); | 833 transport_security_state()->DeleteAllDynamicDataSince(time); |
841 DCHECK(http_server_properties_manager_); | 834 DCHECK(http_server_properties_manager_); |
842 http_server_properties_manager_->Clear(completion); | 835 http_server_properties_manager_->Clear(completion); |
843 } | 836 } |
OLD | NEW |