OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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.exportPath('options'); | 5 cr.exportPath('options'); |
6 | 6 |
7 /** | 7 /** |
8 * @typedef {{actionLinkText: (string|undefined), | 8 * @typedef {{actionLinkText: (string|undefined), |
9 * childUser: (boolean|undefined), | 9 * childUser: (boolean|undefined), |
10 * hasError: (boolean|undefined), | 10 * hasError: (boolean|undefined), |
(...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
456 var value = (event.target.checked ? | 456 var value = (event.target.checked ? |
457 NetworkPredictionOptions.WIFI_ONLY : | 457 NetworkPredictionOptions.WIFI_ONLY : |
458 NetworkPredictionOptions.NEVER); | 458 NetworkPredictionOptions.NEVER); |
459 var metric = event.target.metric; | 459 var metric = event.target.metric; |
460 Preferences.setIntegerPref( | 460 Preferences.setIntegerPref( |
461 'net.network_prediction_options', | 461 'net.network_prediction_options', |
462 value, | 462 value, |
463 true, | 463 true, |
464 metric); | 464 metric); |
465 }; | 465 }; |
| 466 if (loadTimeData.valueExists('showWakeOnWifi') && |
| 467 loadTimeData.getBoolean('showWakeOnWifi')) { |
| 468 $('wake-on-wifi').hidden = false; |
| 469 } |
466 | 470 |
467 // Bluetooth (CrOS only). | 471 // Bluetooth (CrOS only). |
468 if (cr.isChromeOS) { | 472 if (cr.isChromeOS) { |
469 options.system.bluetooth.BluetoothDeviceList.decorate( | 473 options.system.bluetooth.BluetoothDeviceList.decorate( |
470 $('bluetooth-paired-devices-list')); | 474 $('bluetooth-paired-devices-list')); |
471 | 475 |
472 $('bluetooth-add-device').onclick = | 476 $('bluetooth-add-device').onclick = |
473 this.handleAddBluetoothDevice_.bind(this); | 477 this.handleAddBluetoothDevice_.bind(this); |
474 | 478 |
475 $('enable-bluetooth').onchange = function(event) { | 479 $('enable-bluetooth').onchange = function(event) { |
(...skipping 1722 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2198 } | 2202 } |
2199 button.textContent = loadTimeData.getString(strId); | 2203 button.textContent = loadTimeData.getString(strId); |
2200 }; | 2204 }; |
2201 } | 2205 } |
2202 | 2206 |
2203 // Export | 2207 // Export |
2204 return { | 2208 return { |
2205 BrowserOptions: BrowserOptions | 2209 BrowserOptions: BrowserOptions |
2206 }; | 2210 }; |
2207 }); | 2211 }); |
OLD | NEW |