Chromium Code Reviews| Index: ui/webui/resources/cr_elements/policy/cr_policy_pref_indicator.js |
| diff --git a/ui/webui/resources/cr_elements/policy/cr_policy_pref_indicator.js b/ui/webui/resources/cr_elements/policy/cr_policy_pref_indicator.js |
| index 5526eb54d0eaef62e5056b4c1d63994bf6a4478b..b90b0de1eb65270649e07c4835cc6dd04b6716c1 100644 |
| --- a/ui/webui/resources/cr_elements/policy/cr_policy_pref_indicator.js |
| +++ b/ui/webui/resources/cr_elements/policy/cr_policy_pref_indicator.js |
| @@ -23,7 +23,7 @@ Polymer({ |
| * Which indicator type to show (or NONE). |
| * @type {CrPolicyIndicatorType} |
|
michaelpg
2017/02/15 02:02:11
@private?
stevenjb
2017/02/15 02:23:29
Done.
|
| */ |
| - indicatorType: { |
| + indicatorType_: { |
| type: String, |
| value: CrPolicyIndicatorType.NONE, |
| computed: 'getIndicatorType(pref.controlledBy, pref.enforcement)', |
| @@ -32,20 +32,19 @@ Polymer({ |
| /** |
| * @param {CrPolicyIndicatorType} type |
| - * @param {!chrome.settingsPrivate.PrefObject} pref |
| * @return {string} The tooltip text for |type|. |
| * @private |
| */ |
| - getTooltip_: function(type, pref) { |
| - var matches = pref && pref.value == pref.recommendedValue; |
| + getTooltip_: function(type) { |
| + var matches = !!this.pref && this.pref.value == this.pref.recommendedValue; |
| return this.getPolicyIndicatorTooltip( |
| - type, pref.controlledByName || '', matches); |
| + type, this.pref.controlledByName || '', matches); |
| }, |
| /** |
| * @return {boolean} Whether the policy indicator is on. Useful for testing. |
| */ |
| isActive: function() { |
| - return this.isIndicatorVisible(this.indicatorType); |
| + return this.isIndicatorVisible(this.indicatorType_); |
| }, |
| }); |