diff options
| author | Matthew Xie <mattx@google.com> | 2011-07-29 18:57:58 -0700 |
|---|---|---|
| committer | Matthew Xie <mattx@google.com> | 2011-08-02 15:22:09 -0700 |
| commit | 8594394aadeaaa3f834d33d7b198fb071e0f31fe (patch) | |
| tree | cd765ec51f9d90188f4beb3e03b851b5d3fd9344 /core/java/android/server/BluetoothEventLoop.java | |
| parent | c98c3597abf90ff547e1543923cba937e268a7df (diff) | |
| download | frameworks_base-8594394aadeaaa3f834d33d7b198fb071e0f31fe.zip frameworks_base-8594394aadeaaa3f834d33d7b198fb071e0f31fe.tar.gz frameworks_base-8594394aadeaaa3f834d33d7b198fb071e0f31fe.tar.bz2 | |
Move mBluetoothService.runBluetooth after broadcasting the STATE_ON intent.
This is because broadcastState method move the Bluetooth adapter state
to ON. The mBluetoothService.runBluetooth should be called only in the ON state.
Remove mIsDiscovering variable in BluetoothService.
Fix a bug in BluetoothA2dpService that caused 2 times of state change
from DISCONNECTED to CONNECTING that messed up BluetoothService's
connection state count.
Change-Id: Ifb782a845ae70f007d2e036d930bb55f445d68b5
Diffstat (limited to 'core/java/android/server/BluetoothEventLoop.java')
| -rw-r--r-- | core/java/android/server/BluetoothEventLoop.java | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/core/java/android/server/BluetoothEventLoop.java b/core/java/android/server/BluetoothEventLoop.java index 9b9196a..3359bf9 100644 --- a/core/java/android/server/BluetoothEventLoop.java +++ b/core/java/android/server/BluetoothEventLoop.java @@ -359,12 +359,10 @@ class BluetoothEventLoop { Intent intent; adapterProperties.setProperty(name, propValues[1]); if (propValues[1].equals("true")) { - mBluetoothService.setIsDiscovering(true); intent = new Intent(BluetoothAdapter.ACTION_DISCOVERY_STARTED); } else { // Stop the discovery. mBluetoothService.cancelDiscovery(); - mBluetoothService.setIsDiscovering(false); intent = new Intent(BluetoothAdapter.ACTION_DISCOVERY_FINISHED); } mContext.sendBroadcast(intent, BLUETOOTH_PERM); |
