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

Unified Diff: chrome/browser/profiles/profile_impl.cc

Issue 5915004: Introduce incognito preference settings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Continued work from last year Created 9 years, 12 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/profiles/profile_impl.cc
diff --git a/chrome/browser/profiles/profile_impl.cc b/chrome/browser/profiles/profile_impl.cc
index 2c610e19ec17d86c1f589e2d918a4922306e283e..8160ed61446b9252c136599e19acd606841c5fef 100644
--- a/chrome/browser/profiles/profile_impl.cc
+++ b/chrome/browser/profiles/profile_impl.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -661,7 +661,9 @@ net::TransportSecurityState*
PrefService* ProfileImpl::GetPrefs() {
if (!prefs_.get()) {
- ExtensionPrefStore* extension_pref_store = new ExtensionPrefStore;
+ ExtensionPrefStore* extension_pref_store = new ExtensionPrefStore(false);
+ ExtensionPrefStore* incognito_extension_pref_store =
+ new ExtensionPrefStore(true);
prefs_.reset(PrefService::CreatePrefService(GetPrefFilePath(),
extension_pref_store,
GetOriginalProfile()));
@@ -682,10 +684,12 @@ PrefService* ProfileImpl::GetPrefs() {
// Ensure that preferences set by extensions are restored in the profile
// as early as possible. The constructor takes care of that.
+
extension_prefs_.reset(new ExtensionPrefs(
prefs_.get(),
GetPath().AppendASCII(ExtensionService::kInstallDirectoryName),
- extension_pref_store));
+ extension_pref_store,
+ incognito_extension_pref_store));
DCHECK(!net_pref_observer_.get());
net_pref_observer_.reset(new NetPrefObserver(prefs_.get()));

Powered by Google App Engine
This is Rietveld 408576698