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

Unified Diff: chrome/browser/resources/settings/internet_page/network_proxy.js

Issue 1369403006: Add cr-policy-network-indicator and add to internet settings (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Separate policy indicator strings Created 5 years, 2 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/resources/settings/internet_page/network_proxy.js
diff --git a/chrome/browser/resources/settings/internet_page/network_proxy.js b/chrome/browser/resources/settings/internet_page/network_proxy.js
index c7c02e631d2d7d3c4cc6e3a11c09ce964faff4ad..a18f5df31c77404d4245311528cfe0635803ede4 100644
--- a/chrome/browser/resources/settings/internet_page/network_proxy.js
+++ b/chrome/browser/resources/settings/internet_page/network_proxy.js
@@ -9,6 +9,8 @@
Polymer({
is: 'network-proxy',
+ behaviors: [CrPolicyNetworkBehavior],
+
properties: {
/**
* The network properties dictionary containing the proxy properties to
@@ -256,6 +258,21 @@ Polymer({
},
/**
+ * @param {boolean} editable
+ * @param {!CrOnc.NetworkProperties} networkProperties
+ * @param {string} key
+ * @return {boolean} Whether the property is editable.
+ * @private
+ */
+ isPropertyEditable_: function(editable, networkProperties, key) {
+ if (!editable)
+ return false;
+ var property = /** @type {!CrOnc.NetworkProperty|undefined} */(
+ this.get(key, networkProperties));
+ return !this.isNetworkPolicyEnforced(property);
+ },
+
+ /**
* @param {string} property The property to test
* @param {string} value The value to test against
* @return {boolean} True if property == value

Powered by Google App Engine
This is Rietveld 408576698