History log of /frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/BluetoothEventManager.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
515204766578fd12dc1103bc194add9218a01746 24-Jul-2017 Jack He <siyuanh@google.com> CachedBluetoothDevice: Rename mVisible to mJustDiscovered

* CachedBluetoothDevice's member mVisible does not mean whether the
device is visible. Instead, based on its current usage in the library,
it indicates whether the device was just discovered by SettingsLib.
* Rename the field to mJustDiscovered and associated setters and
getters.
* This paves way for future addition of mVisible to indicate whether the
device should be visible to user in the UI.

Bug: 34685932
Test: build only, no functional changes
Change-Id: I616904e6d5bb27dbae74f94819eb0e8607a16e20
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/BluetoothEventManager.java
61ad5ae921d75d0f72e8477ce224a1f7562ae81d 03-Aug-2017 Andre Eisenbach <eisenbach@google.com> Remove "Couldn't pair" prompt on ACTION_PAIRING_CANCEL

ACTION_PAIRING_CANCEL is triggered as a result of an ACL connection
going down, causing a "Couldn't pair" prompt. This can happen on some
car kits, even if the pairing is successful and the car kit briefly
tearing down the ACL connection after pairing and resuming it
immediately afterwards.

If a connection gets disconnected during a normal bonding procedure, the
UNBOND_REASON_REMOTE_DEVICE_DOWN reason code for the
ACTION_BOND_STATE_CHANGED already indicates this issue and will inform
the user.

Bug: 63975046
Test: manual
Change-Id: I663d8b7700741927c72e38e30cd993c0b81511a9
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/BluetoothEventManager.java
6258aae54824a7c3cd3974822b0b6835ab8a45de 30-Jun-2017 Jack He <siyuanh@google.com> Bluetooth: Display battery level of connected devices

* Add handler for BluetoothDevice.ACTION_BATTERY_LEVEL_CHANGED intent
* Check battery level information when UI is updated
* Show battery level in Quick Settings connected device summary line
* Show battery level in Bluetooth Settings connected device summary line
* Show battery level in Bluetooth device details page device summary
line
* Add unit test for CachedBluetoothDevice, change HeadsetProfile and
HidProfile to not final to enable mocking

Bug: 35874078
Test: make, unit test, connect to remote devices, connect/disconnect
profiles
Change-Id: I729048cace73aab29337a8002a2897d2acf22fa6
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/BluetoothEventManager.java
82dd3b0bf6716ccee0f82b2b2db234cdefd34ff6 27-Dec-2016 Fan Zhang <zhfan@google.com> Make classes non-final so mockito can mock them.

Bug: 33341275
Test: RunSettingsRoboTests
Change-Id: If83180d7caf3af29c9d0dcdc20d557d8d9827c74
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/BluetoothEventManager.java
3eb490f903513da26b69cf50398a711829614bff 18-Jul-2016 Jakub Pawlowski <jpawlowski@google.com> Fix Bluetooth OOB pairing not working for unseen devices

When Out Of Band info is provided, first time we learn about
device is when it's state is changed to "Bonding". This currently cause
this event to be discarded and pairing fails. Instead, we should add
CachedDevice object for newly added device.

Bug: 30188629
Change-Id: I4046bfe30e8bf32b888f608ac06d5041e2999dc9
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/BluetoothEventManager.java
4d08a485db5021638b0abcb8675ba00579bd7fcc 07-Jul-2015 Sanket Padawe <sanketpadawe@google.com> Add Null checks while processing pairing cancel intent

Use case: Exception while handling pairing cancel
Intent received
1. Initiate pairing from DUT to remote
2. Power off DUT after getting pairing popup

Root Cause:Crash observed in settings application

Change-Id: Ia05fe196ecf6a1d4ec26f85b0cf984e23089c728
Fix: Fixed by adding Null check in PairingCancelHandler
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/BluetoothEventManager.java
107cb81f9054a406b94e249c99fd7d64be71faec 25-Jun-2015 Jason Monk <jmonk@google.com> Merge "Make BluetoothEventManager listen to ALIAS_CHANGED" into mnc-dev
d2b033aeb4123ec92892495c262e0272ffb7ecdc 04-Jun-2015 Pavlin Radoslavov <pavlin@google.com> Add a missing check for null pointer.

There is a race condition when processing intents inside
PairingCancelHandler.onReceive() that could trigger NPE.
A speculative list of events (untested) that could trigger it:

1. Trigger Pairing Cancel for a Bluetooth device.
2. Turn Off Bluetooth
This should call CachedBluetoothDeviceManager.onBluetoothStateChanged()
and should remove the device from (1) from the list of cached devices
3. BluetoothEventManager.PairincCancelHander.onReceive() receives
an intent about about Pairing Cancel event.
Within the processing of that intent, cachedDevice.getName()
is called without checking whether cachedDevice is null.
In this specific example, cachedDevice could be null because of (2)

Bug: 21368124
Change-Id: I86f5d5287b440d1d2e0fe147278b1c2257902e95
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/BluetoothEventManager.java
8c495be48fc6973cc291fb4e6200154e2f28d571 03-Jun-2015 Jason Monk <jmonk@google.com> Make BluetoothEventManager listen to ALIAS_CHANGED

Bug: 20341903
Change-Id: Ibc0836bfd7f033f57ff6ae9c3ccce22fd92595f3
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/BluetoothEventManager.java
744cf647f71b1e5a012a90ef195bf2c3c486f418 19-May-2015 Jason Monk <jmonk@google.com> SysUI: Move BT receivers to bg

Bug: 19520495
Change-Id: I58e7d023b9eaf67fccd1634e00803c8c8d871fff
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/BluetoothEventManager.java
be3c5dbee66758517a8198f98ed2e20c80af326b 04-Feb-2015 Jason Monk <jmonk@google.com> Make QS use SettingsLib's BT code

A couple of changes needed to be made to SettingsLib to support this.
- SettingsLib needed to track ACTION_CONNECTION_STATE_CHANGED
- The summary code needed to move from Settings up into SettingsLib
- Added a getMaxConnectionState to CachedBluetoothDevice
- This simplifies the states of all of the profiles into
one.

Change-Id: I7f828f0038ad0cf39274986ece6d486d545f0286
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/BluetoothEventManager.java
7ce96b9e610de2782ec5f2af806e7bc0f90c8578 02-Feb-2015 Jason Monk <jmonk@google.com> Move non-ui bt settings code to SettingsLib

Mostly this is moving classes from Settings to SettingsLib but there
were a few changes to support this separation.
- A bunch of things became public rather than package
- Moved some settings only code out of these classes
- Added error callback to handle errors

To see the changes from original classes view the diff against
patch-set 1.

Bug: 19180466
Change-Id: I69fd888362c6dbb325f6113b32c4b15cc6a23a41
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/BluetoothEventManager.java