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

Unified Diff: chrome/browser/prefs/incognito_mode_prefs.cc

Issue 136693011: Disable incognito if parental controls are enabled on android. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 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
« no previous file with comments | « chrome/browser/android/chromium_application.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/prefs/incognito_mode_prefs.cc
diff --git a/chrome/browser/prefs/incognito_mode_prefs.cc b/chrome/browser/prefs/incognito_mode_prefs.cc
index 7ca0e29ffc422763127a2bf778ab0c02f1b04ed5..d1c21d5aa0c0eb2d9da563ae946be851346ce7da 100644
--- a/chrome/browser/prefs/incognito_mode_prefs.cc
+++ b/chrome/browser/prefs/incognito_mode_prefs.cc
@@ -14,7 +14,9 @@
#if defined(OS_WIN)
#include "base/win/metro.h"
-#endif // OS_WIN
+#elif defined(OS_ANDROID)
Bernhard Bauer 2014/01/14 09:59:07 Nit: I'd rather keep these #ifdefs separate (it re
Ted C 2014/01/15 00:15:49 Done.
+#include "chrome/browser/android/chromium_application.h"
+#endif
// static
bool IncognitoModePrefs::IntToAvailability(int in_value,
@@ -43,6 +45,9 @@ IncognitoModePrefs::Availability IncognitoModePrefs::GetAvailability(
LOG(ERROR) << "Ignoring FORCED incognito. Parental control logging on";
return IncognitoModePrefs::DISABLED;
}
+#elif defined(OS_ANDROID)
+ if (chrome::android::ChromiumApplication::AreParentalControlsEnabled())
+ return IncognitoModePrefs::DISABLED;
#endif // OS_WIN
return result;
}
« no previous file with comments | « chrome/browser/android/chromium_application.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698