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

Unified Diff: chrome/browser/policy/configuration_policy_handler.cc

Issue 9264070: Set prefs::kDefaultSearchProviderEnabled to false according to policy. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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
Index: chrome/browser/policy/configuration_policy_handler.cc
diff --git a/chrome/browser/policy/configuration_policy_handler.cc b/chrome/browser/policy/configuration_policy_handler.cc
index b29c567fc7e229a2af986b6666bcafbd2992aeef..354abc179d21d596c00f5cb2fa68006537da720f 100644
--- a/chrome/browser/policy/configuration_policy_handler.cc
+++ b/chrome/browser/policy/configuration_policy_handler.cc
@@ -514,6 +514,8 @@ bool DefaultSearchPolicyHandler::CheckPolicySettings(const PolicyMap& policies,
void DefaultSearchPolicyHandler::ApplyPolicySettings(const PolicyMap& policies,
PrefValueMap* prefs) {
if (DefaultSearchProviderIsDisabled(policies)) {
+ prefs->SetBoolean(prefs::kDefaultSearchProviderEnabled, false);
+
// If default search is disabled, the other fields are ignored.
prefs->SetString(prefs::kDefaultSearchProviderName, std::string());
prefs->SetString(prefs::kDefaultSearchProviderSearchURL, std::string());

Powered by Google App Engine
This is Rietveld 408576698