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

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

Issue 7520023: Converted IncognitoForced boolean policy into IncognitoModeAvailability enum policy. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Created 9 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/profiles/profile.cc
diff --git a/chrome/browser/profiles/profile.cc b/chrome/browser/profiles/profile.cc
index 933ffd10781b3be67a0480b8e84e8958e0ead3a7..3c7f6d68151d3a1fc439ac8b45d5b6699de32621 100644
--- a/chrome/browser/profiles/profile.cc
+++ b/chrome/browser/profiles/profile.cc
@@ -26,6 +26,7 @@
#include "chrome/browser/extensions/extension_special_storage_policy.h"
#include "chrome/browser/extensions/extension_webrequest_api.h"
#include "chrome/browser/net/pref_proxy_config_service.h"
+#include "chrome/browser/prefs/incognito_mode_availability_prefs.h"
#include "chrome/browser/prefs/pref_service.h"
#include "chrome/browser/profiles/off_the_record_profile_io_data.h"
#include "chrome/browser/profiles/profile_dependency_manager.h"
@@ -237,7 +238,10 @@ class OffTheRecordProfileImpl : public Profile,
ProfileDependencyManager::GetInstance()->CreateProfileServices(this, false);
- DCHECK(real_profile->GetPrefs()->GetBoolean(prefs::kIncognitoEnabled));
+ DCHECK_NE(
+ IncognitoModeAvailabilityPrefs::DISABLED,
+ real_profile->GetPrefs()->GetInteger(
+ prefs::kIncognitoModeAvailability));
// TODO(oshima): Remove the need to eagerly initialize the request context
// getter. chromeos::OnlineAttempt is illegally trying to access this

Powered by Google App Engine
This is Rietveld 408576698