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

Unified Diff: components/policy/core/common/proxy_policy_provider.cc

Issue 1304843004: Add source column to chrome://policy showing the origins of policies. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 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: components/policy/core/common/proxy_policy_provider.cc
diff --git a/components/policy/core/common/proxy_policy_provider.cc b/components/policy/core/common/proxy_policy_provider.cc
index 7a8919759c20fdbe9d0535a18f4df3e587518483..382f0a3992ea47b9c58feb051809065c14f8ac70 100644
--- a/components/policy/core/common/proxy_policy_provider.cc
+++ b/components/policy/core/common/proxy_policy_provider.cc
@@ -21,6 +21,7 @@ void ProxyPolicyProvider::SetDelegate(ConfigurationPolicyProvider* delegate) {
delegate_->RemoveObserver(this);
delegate_ = delegate;
if (delegate_) {
+ source_ = delegate_->source();
delegate_->AddObserver(this);
OnUpdatePolicy(delegate_);
} else {
@@ -35,6 +36,7 @@ void ProxyPolicyProvider::Shutdown() {
if (delegate_) {
delegate_->RemoveObserver(this);
delegate_ = NULL;
+ source_ = POLICY_SOURCE_UNKNOWN;
bartfab (slow) 2015/09/14 14:42:27 Nit 1: #include "components/policy/core/common/pol
fhorschig 2015/09/16 13:52:05 Done.
}
ConfigurationPolicyProvider::Shutdown();
}

Powered by Google App Engine
This is Rietveld 408576698