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

Side by Side Diff: chrome/browser/profiles/profile_impl_io_data.cc

Issue 380003002: Improve testing for SDCH. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed braino: Added SDHC enable to the tests that need it. Created 6 years, 5 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 | Annotate | Revision Log
OLDNEW
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 478 matching lines...) Expand 10 before | Expand all | Expand 10 after
489 network_delegate(), 489 network_delegate(),
490 ftp_factory_.get()); 490 ftp_factory_.get());
491 main_context->set_job_factory(main_job_factory_.get()); 491 main_context->set_job_factory(main_job_factory_.get());
492 492
493 #if defined(ENABLE_EXTENSIONS) 493 #if defined(ENABLE_EXTENSIONS)
494 InitializeExtensionsRequestContext(profile_params); 494 InitializeExtensionsRequestContext(profile_params);
495 #endif 495 #endif
496 496
497 // Setup the SDCHManager for this profile. 497 // Setup the SDCHManager for this profile.
498 sdch_manager_.reset(new net::SdchManager); 498 sdch_manager_.reset(new net::SdchManager);
499 sdch_manager_->set_sdch_fetcher( 499 scoped_ptr<net::SdchFetcher> fetcher(new net::SdchDictionaryFetcher(
500 new net::SdchDictionaryFetcher( 500 sdch_manager_.get(),
501 sdch_manager_.get(), 501 // SdchDictionaryFetcher takes a reference to the Getter, and
502 // SdchDictionaryFetcher takes a reference to the Getter, and 502 // hence implicitly takes ownership.
503 // hence implicitly takes ownership. 503 new net::TrivialURLRequestContextGetter(
504 new net::TrivialURLRequestContextGetter( 504 main_context,
505 main_context, 505 content::BrowserThread::GetMessageLoopProxyForThread(
506 content::BrowserThread::GetMessageLoopProxyForThread( 506 content::BrowserThread::IO))));
507 content::BrowserThread::IO)))); 507 sdch_manager_->set_sdch_fetcher(fetcher.Pass());
jar (doing other things) 2014/07/31 03:24:34 nit: perhaps putting results from new at line 503
Randy Smith (Not in Mondays) 2014/08/11 20:33:25 See earlier reply.
508 main_context->set_sdch_manager(sdch_manager_.get()); 508 main_context->set_sdch_manager(sdch_manager_.get());
509 509
510 // Create a media request context based on the main context, but using a 510 // Create a media request context based on the main context, but using a
511 // media cache. It shares the same job factory as the main context. 511 // media cache. It shares the same job factory as the main context.
512 StoragePartitionDescriptor details(profile_path_, false); 512 StoragePartitionDescriptor details(profile_path_, false);
513 media_request_context_.reset(InitializeMediaRequestContext(main_context, 513 media_request_context_.reset(InitializeMediaRequestContext(main_context,
514 details)); 514 details));
515 515
516 if (domain_reliability_monitor_) { 516 if (domain_reliability_monitor_) {
517 domain_reliability_monitor_->Init( 517 domain_reliability_monitor_->Init(
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
750 const base::Closure& completion) { 750 const base::Closure& completion) {
751 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); 751 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
752 DCHECK(initialized()); 752 DCHECK(initialized());
753 753
754 DCHECK(transport_security_state()); 754 DCHECK(transport_security_state());
755 // Completes synchronously. 755 // Completes synchronously.
756 transport_security_state()->DeleteAllDynamicDataSince(time); 756 transport_security_state()->DeleteAllDynamicDataSince(time);
757 DCHECK(http_server_properties_manager_); 757 DCHECK(http_server_properties_manager_);
758 http_server_properties_manager_->Clear(completion); 758 http_server_properties_manager_->Clear(completion);
759 } 759 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698