OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 cr.define('options', function() { | 5 cr.define('options', function() { |
6 | 6 |
7 var OptionsPage = options.OptionsPage; | 7 var OptionsPage = options.OptionsPage; |
8 var RepeatingButton = cr.ui.RepeatingButton; | 8 var RepeatingButton = cr.ui.RepeatingButton; |
9 | 9 |
10 ///////////////////////////////////////////////////////////////////////////// | 10 ///////////////////////////////////////////////////////////////////////////// |
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
181 /** | 181 /** |
182 * Hides the scanning label and icon that are used to indicate that a device | 182 * Hides the scanning label and icon that are used to indicate that a device |
183 * search is in progress. | 183 * search is in progress. |
184 */ | 184 */ |
185 SystemOptions.notifyBluetoothSearchComplete = function() { | 185 SystemOptions.notifyBluetoothSearchComplete = function() { |
186 setVisibility_('bluetooth-scanning-label', false); | 186 setVisibility_('bluetooth-scanning-label', false); |
187 setVisibility_('bluetooth-scanning-icon', false); | 187 setVisibility_('bluetooth-scanning-icon', false); |
188 }; | 188 }; |
189 | 189 |
190 /** | 190 /** |
191 * Displays the Touchpad Controls section when we detect a touchpad. | 191 * Displays the touchpad controls section when we detect a touchpad, hides it |
| 192 * otherwise. |
192 */ | 193 */ |
193 SystemOptions.showTouchpadControls = function() { | 194 SystemOptions.showTouchpadControls = function(show) { |
194 $('touchpad-controls').hidden = false; | 195 $('touchpad-controls').hidden = !show; |
| 196 }; |
| 197 |
| 198 /** |
| 199 * Displays the mouse controls section when we detect a mouse, hides it |
| 200 * otherwise. |
| 201 */ |
| 202 SystemOptions.showMouseControls = function(show) { |
| 203 $('mouse-controls').hidden = !show; |
195 }; | 204 }; |
196 | 205 |
197 // Export | 206 // Export |
198 return { | 207 return { |
199 SystemOptions: SystemOptions | 208 SystemOptions: SystemOptions |
200 }; | 209 }; |
201 | 210 |
202 }); | 211 }); |
OLD | NEW |