OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 /** | 5 /** |
6 * @fileoverview Behavior for policy controlled network properties. | 6 * @fileoverview Behavior for policy controlled network properties. |
7 */ | 7 */ |
8 | 8 |
9 /** @polymerBehavior */ | 9 /** @polymerBehavior */ |
10 var CrPolicyNetworkBehavior = { | 10 var CrPolicyNetworkBehavior = { |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
73 * @param {string|undefined} source | 73 * @param {string|undefined} source |
74 * @return {boolean} | 74 * @return {boolean} |
75 * @private | 75 * @private |
76 */ | 76 */ |
77 isPolicySource: function(source) { | 77 isPolicySource: function(source) { |
78 return !!source && (source == CrOnc.Source.DEVICE_POLICY || | 78 return !!source && (source == CrOnc.Source.DEVICE_POLICY || |
79 source == CrOnc.Source.USER_POLICY); | 79 source == CrOnc.Source.USER_POLICY); |
80 }, | 80 }, |
81 | 81 |
82 /** | 82 /** |
83 * @param {String} source | 83 * @param {string} source |
84 * @return {!CrPolicyIndicatorType} | 84 * @return {!CrPolicyIndicatorType} |
85 * @private | 85 * @private |
86 */ | 86 */ |
87 getIndicatorTypeForSource: function(source) { | 87 getIndicatorTypeForSource: function(source) { |
88 if (source == CrOnc.Source.DEVICE_POLICY) | 88 if (source == CrOnc.Source.DEVICE_POLICY) |
89 return CrPolicyIndicatorType.DEVICE_POLICY; | 89 return CrPolicyIndicatorType.DEVICE_POLICY; |
90 if (source == CrOnc.Source.USER_POLICY) | 90 if (source == CrOnc.Source.USER_POLICY) |
91 return CrPolicyIndicatorType.USER_POLICY; | 91 return CrPolicyIndicatorType.USER_POLICY; |
92 return CrPolicyIndicatorType.NONE; | 92 return CrPolicyIndicatorType.NONE; |
93 }, | 93 }, |
94 }; | 94 }; |
OLD | NEW |