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

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

Issue 6825038: Create a content::ResourceContext. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix dependencies. Created 9 years, 8 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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.h" 5 #include "chrome/browser/profiles/profile.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 410 matching lines...) Expand 10 before | Expand all | Expand 10 after
421 return GetRequestContextForIsolatedApp(installed_app->id()); 421 return GetRequestContextForIsolatedApp(installed_app->id());
422 422
423 return GetRequestContext(); 423 return GetRequestContext();
424 } 424 }
425 425
426 virtual net::URLRequestContextGetter* GetRequestContextForMedia() { 426 virtual net::URLRequestContextGetter* GetRequestContextForMedia() {
427 // In OTR mode, media request context is the same as the original one. 427 // In OTR mode, media request context is the same as the original one.
428 return io_data_.GetMainRequestContextGetter(); 428 return io_data_.GetMainRequestContextGetter();
429 } 429 }
430 430
431 net::URLRequestContextGetter* GetRequestContextForExtensions() { 431 virtual net::URLRequestContextGetter* GetRequestContextForExtensions() {
432 return io_data_.GetExtensionsRequestContextGetter(); 432 return io_data_.GetExtensionsRequestContextGetter();
433 } 433 }
434 434
435 net::URLRequestContextGetter* GetRequestContextForIsolatedApp( 435 virtual net::URLRequestContextGetter* GetRequestContextForIsolatedApp(
436 const std::string& app_id) { 436 const std::string& app_id) {
437 return io_data_.GetIsolatedAppRequestContextGetter(app_id); 437 return io_data_.GetIsolatedAppRequestContextGetter(app_id);
438 } 438 }
439 439
440 virtual const content::ResourceContext& GetResourceContext() {
441 return io_data_.GetResourceContext();
442 }
443
440 virtual net::SSLConfigService* GetSSLConfigService() { 444 virtual net::SSLConfigService* GetSSLConfigService() {
441 return profile_->GetSSLConfigService(); 445 return profile_->GetSSLConfigService();
442 } 446 }
443 447
444 virtual HostContentSettingsMap* GetHostContentSettingsMap() { 448 virtual HostContentSettingsMap* GetHostContentSettingsMap() {
445 // Retrieve the host content settings map of the parent profile in order to 449 // Retrieve the host content settings map of the parent profile in order to
446 // ensure the preferences have been migrated. 450 // ensure the preferences have been migrated.
447 profile_->GetHostContentSettingsMap(); 451 profile_->GetHostContentSettingsMap();
448 if (!host_content_settings_map_.get()) 452 if (!host_content_settings_map_.get())
449 host_content_settings_map_ = new HostContentSettingsMap(this); 453 host_content_settings_map_ = new HostContentSettingsMap(this);
(...skipping 330 matching lines...) Expand 10 before | Expand all | Expand 10 after
780 }; 784 };
781 #endif 785 #endif
782 786
783 Profile* Profile::CreateOffTheRecordProfile() { 787 Profile* Profile::CreateOffTheRecordProfile() {
784 #if defined(OS_CHROMEOS) 788 #if defined(OS_CHROMEOS)
785 if (Profile::IsGuestSession()) 789 if (Profile::IsGuestSession())
786 return new GuestSessionProfile(this); 790 return new GuestSessionProfile(this);
787 #endif 791 #endif
788 return new OffTheRecordProfileImpl(this); 792 return new OffTheRecordProfileImpl(this);
789 } 793 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698