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

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

Issue 9704092: Adds a device policy to specify the set of initial urls for the demo user account. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed issues and rebases to ToT. Created 8 years, 9 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/device_policy_cache.cc
diff --git a/chrome/browser/policy/device_policy_cache.cc b/chrome/browser/policy/device_policy_cache.cc
index c80a120db0a171c3075ac038fa4eeccefb78520b..d3a121d1fcb7cc69072ef5e2dd86a0520fc4976e 100644
--- a/chrome/browser/policy/device_policy_cache.cc
+++ b/chrome/browser/policy/device_policy_cache.cc
@@ -570,6 +570,23 @@ void DevicePolicyCache::DecodeGenericPolicies(
Value::CreateBooleanValue(container.update_disabled()));
}
}
+
+ if (policy.has_start_up_urls()) {
+ const em::StartUpUrlsProto& container(policy.start_up_urls());
+ if (container.start_up_urls_size()) {
+ ListValue* urls = new ListValue();
+ RepeatedPtrField<std::string>::const_iterator entry;
+ for (entry = container.start_up_urls().begin();
+ entry != container.start_up_urls().end();
+ ++entry) {
+ urls->Append(Value::CreateStringValue(*entry));
+ }
+ policies->Set(key::kDeviceStartUpUrls,
+ POLICY_LEVEL_MANDATORY,
+ POLICY_SCOPE_MACHINE,
+ urls);
+ }
+ }
}
// static
« no previous file with comments | « chrome/browser/chromeos/login/existing_user_controller.cc ('k') | chrome/browser/policy/proto/chrome_device_policy.proto » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698