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

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

Issue 7838030: WIP: Introduce per-TabContents PrefService. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 3 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 300 matching lines...) Expand 10 before | Expand all | Expand 10 after
311 } 311 }
312 312
313 virtual PrefService* GetPrefs() { 313 virtual PrefService* GetPrefs() {
314 return prefs_; 314 return prefs_;
315 } 315 }
316 316
317 virtual PrefService* GetOffTheRecordPrefs() { 317 virtual PrefService* GetOffTheRecordPrefs() {
318 return prefs_; 318 return prefs_;
319 } 319 }
320 320
321 virtual PrefService* GetPrefsForTabContents(TabContents* contents) {
322 // TODO: How should this behave?
323 return NULL;
324 }
325
321 virtual TemplateURLFetcher* GetTemplateURLFetcher() { 326 virtual TemplateURLFetcher* GetTemplateURLFetcher() {
322 return profile_->GetTemplateURLFetcher(); 327 return profile_->GetTemplateURLFetcher();
323 } 328 }
324 329
325 virtual DownloadManager* GetDownloadManager() { 330 virtual DownloadManager* GetDownloadManager() {
326 if (!download_manager_.get()) { 331 if (!download_manager_.get()) {
327 download_manager_delegate_ = new ChromeDownloadManagerDelegate(this); 332 download_manager_delegate_ = new ChromeDownloadManagerDelegate(this);
328 scoped_refptr<DownloadManager> dlm( 333 scoped_refptr<DownloadManager> dlm(
329 new DownloadManager(download_manager_delegate_, 334 new DownloadManager(download_manager_delegate_,
330 g_browser_process->download_status_updater())); 335 g_browser_process->download_status_updater()));
(...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after
726 }; 731 };
727 #endif 732 #endif
728 733
729 Profile* Profile::CreateOffTheRecordProfile() { 734 Profile* Profile::CreateOffTheRecordProfile() {
730 #if defined(OS_CHROMEOS) 735 #if defined(OS_CHROMEOS)
731 if (Profile::IsGuestSession()) 736 if (Profile::IsGuestSession())
732 return new GuestSessionProfile(this); 737 return new GuestSessionProfile(this);
733 #endif 738 #endif
734 return new OffTheRecordProfileImpl(this); 739 return new OffTheRecordProfileImpl(this);
735 } 740 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698