Put newly discovered devices to the bottom of the list
Add two type SortType.TYPE_DEFAULT and SortType.TYPE_FIFO in BluetoothDevicePreference. It needs to decide the sort type when you create the BluetoothDevicePreference. TYPE_DEFAULT - According to the CacheBluetoothDevice state to sort TYPE_FIFO - According to the timestamp to sort Bug: 112546918 Test: make -j42 RunSettingsRoboTests Change-Id: Icd25d9b76a44d5a105f8daf64e5bc1f9ead8cd92
This commit is contained in:
@@ -99,7 +99,8 @@ public class BluetoothDeviceUpdaterTest {
|
||||
when(mCachedBluetoothDevice.getAddress()).thenReturn(MAC_ADDRESS);
|
||||
when(mSubBluetoothDevice.getAddress()).thenReturn(SUB_MAC_ADDRESS);
|
||||
|
||||
mPreference = new BluetoothDevicePreference(mContext, mCachedBluetoothDevice, false);
|
||||
mPreference = new BluetoothDevicePreference(mContext, mCachedBluetoothDevice,
|
||||
false, BluetoothDevicePreference.SortType.TYPE_DEFAULT);
|
||||
mBluetoothDeviceUpdater =
|
||||
new BluetoothDeviceUpdater(mDashboardFragment, mDevicePreferenceCallback,
|
||||
mLocalManager) {
|
||||
|
Reference in New Issue
Block a user