| OLD | NEW |
| (Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 /** |
| 6 * @fileoverview |
| 7 * 'settings-pointers' is the settings subpage with mouse and touchpad settings. |
| 8 */ |
| 9 Polymer({ |
| 10 is: 'settings-pointers', |
| 11 |
| 12 properties: { |
| 13 /** Preferences state. */ |
| 14 prefs: { |
| 15 type: Object, |
| 16 notify: true, |
| 17 }, |
| 18 |
| 19 hasMouse: { |
| 20 type: Boolean, |
| 21 value: false, |
| 22 }, |
| 23 |
| 24 hasTouchpad: { |
| 25 type: Boolean, |
| 26 value: false, |
| 27 }, |
| 28 |
| 29 /** |
| 30 * TODO(michaelpg): cr-slider should optionally take a min and max so we |
| 31 * don't have to generate a simple range of natural numbers ourselves. |
| 32 * @const {!Array<number>} |
| 33 * @private |
| 34 */ |
| 35 sensitivityValues_: { |
| 36 type: Array, |
| 37 value: [1, 2, 3, 4, 5], |
| 38 readOnly: true, |
| 39 }, |
| 40 }, |
| 41 |
| 42 /** |
| 43 * Prevents the link from activating its parent paper-radio-button. |
| 44 * @param {!Event} e |
| 45 * @private |
| 46 */ |
| 47 onLearnMoreLinkActivated_: function(e) { |
| 48 settings.DevicePageBrowserProxyImpl.getInstance().handleLinkEvent(e); |
| 49 }, |
| 50 |
| 51 // Mouse and touchpad sections are only subsections if they are both present. |
| 52 getSectionClass_: function(hasMouse, hasTouchpad) { |
| 53 return hasMouse && hasTouchpad ? 'subsection' : ''; |
| 54 }, |
| 55 }); |
| OLD | NEW |