Commit 446dd408 authored by csilv@chromium.org's avatar csilv@chromium.org

Fix the bluetooth 'add device' button for CrOS.

BUG=none
TEST=Verify that the 'add device' button in the bluetooth section works.
Review URL: https://chromiumcodereview.appspot.com/9567031

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@124708 0039d316-1c4b-4281-b951-d872f2087c98
parent c3e4c4ee
...@@ -282,10 +282,8 @@ cr.define('options', function() { ...@@ -282,10 +282,8 @@ cr.define('options', function() {
options.system.bluetooth.BluetoothDeviceList.decorate( options.system.bluetooth.BluetoothDeviceList.decorate(
$('bluetooth-paired-devices-list')); $('bluetooth-paired-devices-list'));
$('bluetooth-add-device').onclick = function(event) { $('bluetooth-add-device').onclick =
this.findBluetoothDevices_(true); this.handleAddBluetoothDevice_.bind(this);
OptionsPage.navigateToPage('bluetooth');
};
$('enable-bluetooth').onchange = function(event) { $('enable-bluetooth').onchange = function(event) {
var state = $('enable-bluetooth').checked; var state = $('enable-bluetooth').checked;
...@@ -923,14 +921,13 @@ cr.define('options', function() { ...@@ -923,14 +921,13 @@ cr.define('options', function() {
}, },
/** /**
* Scan for bluetooth devices. * Handle the 'add device' button click.
* @param {boolean} reset Indicates if the list of unpaired devices should
* be cleared.
* @private * @private
*/ */
findBluetoothDevices_: function(reset) { handleAddBluetoothDevice_: function() {
$('bluetooth-unpaired-devices-list').clear(); $('bluetooth-unpaired-devices-list').clear();
chrome.send('findBluetoothDevices'); chrome.send('findBluetoothDevices');
OptionsPage.navigateToPage('bluetooth');
}, },
/** /**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment