OSDN Git Service

Bluetooth: Only show devices when their names are resolved
authorJack He <siyuanh@google.com>
Thu, 1 Jun 2017 01:37:28 +0000 (18:37 -0700)
committerJack He <siyuanh@google.com>
Fri, 25 Aug 2017 23:27:30 +0000 (16:27 -0700)
commit19ba3202634762e4670827568b79b45f5793b1ca
tree219bf2346a7bd5921e4306b65d0a4d06103ed1d4
parent77bd8c3a739d5780c2c68b015922258183ae2cc8
Bluetooth: Only show devices when their names are resolved

* Add a developer menu option to allow name-less devices to be shown
  when a Bluetooth developer needs it, but hide it for non-developer
  users.
* Set BluetoothDevicePreference to invisible when CachedBluetoothDevice
  does not have a name besides MAC address and the above developer option
  is false.
* This affects BluetoothPairingDetail and DevicePickerFragment, but does
  not affect BluetoothSettings. BluetoothSettings will show all paired
  devices regardless whether an user friendly name exists.

Bug: 34685932
Test: pair Bluetooth device, send file over Bluetooth, unit tests
Change-Id: Idd7ad4b1671dfdcf3204efb50eddb6dae1065aa5
res/xml/development_prefs.xml
src/com/android/settings/bluetooth/BluetoothDevicePreference.java
src/com/android/settings/bluetooth/BluetoothSettings.java
src/com/android/settings/bluetooth/DeviceListPreferenceFragment.java
src/com/android/settings/development/DevelopmentSettings.java
tests/robotests/src/com/android/settings/bluetooth/BluetoothDevicePreferenceTest.java