| 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 | 6 * @fileoverview |
| 7 * 'settings-search-page' is the settings page containing search settings. | 7 * 'settings-search-page' is the settings page containing search settings. |
| 8 */ | 8 */ |
| 9 Polymer({ | 9 Polymer({ |
| 10 is: 'settings-search-page', | 10 is: 'settings-search-page', |
| (...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 165 // Re-enable hotword search enable; this will trigger the retrain UI. | 165 // Re-enable hotword search enable; this will trigger the retrain UI. |
| 166 this.browserProxy_.setHotwordSearchEnabled(this.hotwordInfo_.enabled); | 166 this.browserProxy_.setHotwordSearchEnabled(this.hotwordInfo_.enabled); |
| 167 }, | 167 }, |
| 168 | 168 |
| 169 /** | 169 /** |
| 170 * @param {Event} event | 170 * @param {Event} event |
| 171 * @private | 171 * @private |
| 172 */ | 172 */ |
| 173 doNothing_: function(event) { | 173 doNothing_: function(event) { |
| 174 event.stopPropagation(); | 174 event.stopPropagation(); |
| 175 } | 175 }, |
| 176 |
| 177 /** |
| 178 * @param {!chrome.settingsPrivate.PrefObject} pref |
| 179 * @return {boolean} |
| 180 * @private |
| 181 */ |
| 182 isDefaultSearchControlledByPolicy_: function(pref) { |
| 183 return pref.controlledBy == chrome.settingsPrivate.ControlledBy.USER_POLICY; |
| 184 }, |
| 185 |
| 186 /** |
| 187 * @param {!chrome.settingsPrivate.PrefObject} pref |
| 188 * @return {boolean} |
| 189 * @private |
| 190 */ |
| 191 isDefaultSearchEngineEnforced_: function(pref) { |
| 192 return pref.enforcement == chrome.settingsPrivate.Enforcement.ENFORCED; |
| 193 }, |
| 176 }); | 194 }); |
| OLD | NEW |