Switch some debug level logging to regular logging in the bluetooth settings for the ease of issue triage.
Change-Id: I9b73d24eb22613f6401c31352efc516f527b30d9 Bug: N/A
This commit is contained in:
@@ -70,9 +70,8 @@ public class AvailableMediaBluetoothDeviceUpdater extends BluetoothDeviceUpdater
|
|||||||
|
|
||||||
boolean isFilterMatched = false;
|
boolean isFilterMatched = false;
|
||||||
if (isDeviceConnected(cachedDevice) && isDeviceInCachedDevicesList(cachedDevice)) {
|
if (isDeviceConnected(cachedDevice) && isDeviceInCachedDevicesList(cachedDevice)) {
|
||||||
if (DBG) {
|
Log.d(TAG, "isFilterMatched() current audio profile : " + currentAudioProfile);
|
||||||
Log.d(TAG, "isFilterMatched() current audio profile : " + currentAudioProfile);
|
|
||||||
}
|
|
||||||
// If device is Hearing Aid, it is compatible with HFP and A2DP.
|
// If device is Hearing Aid, it is compatible with HFP and A2DP.
|
||||||
// It would show in Available Devices group.
|
// It would show in Available Devices group.
|
||||||
if (cachedDevice.isConnectedAshaHearingAidDevice()) {
|
if (cachedDevice.isConnectedAshaHearingAidDevice()) {
|
||||||
@@ -111,14 +110,12 @@ public class AvailableMediaBluetoothDeviceUpdater extends BluetoothDeviceUpdater
|
|||||||
isFilterMatched = cachedDevice.isConnectedHfpDevice();
|
isFilterMatched = cachedDevice.isConnectedHfpDevice();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (DBG) {
|
Log.d(
|
||||||
Log.d(
|
TAG,
|
||||||
TAG,
|
"isFilterMatched() device : "
|
||||||
"isFilterMatched() device : "
|
+ cachedDevice.getName()
|
||||||
+ cachedDevice.getName()
|
+ ", isFilterMatched : "
|
||||||
+ ", isFilterMatched : "
|
+ isFilterMatched);
|
||||||
+ isFilterMatched);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return isFilterMatched;
|
return isFilterMatched;
|
||||||
}
|
}
|
||||||
|
@@ -183,10 +183,8 @@ public abstract class BluetoothDeviceUpdater implements BluetoothCallback,
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onAclConnectionStateChanged(CachedBluetoothDevice cachedDevice, int state) {
|
public void onAclConnectionStateChanged(CachedBluetoothDevice cachedDevice, int state) {
|
||||||
if (DBG) {
|
Log.d(getLogTag(), "onAclConnectionStateChanged() device: " + cachedDevice.getName()
|
||||||
Log.d(getLogTag(), "onAclConnectionStateChanged() device: " + cachedDevice.getName()
|
+ ", state: " + state);
|
||||||
+ ", state: " + state);
|
|
||||||
}
|
|
||||||
update(cachedDevice);
|
update(cachedDevice);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -38,7 +38,6 @@ public class SavedBluetoothDeviceUpdater extends BluetoothDeviceUpdater
|
|||||||
implements Preference.OnPreferenceClickListener {
|
implements Preference.OnPreferenceClickListener {
|
||||||
|
|
||||||
private static final String TAG = "SavedBluetoothDeviceUpdater";
|
private static final String TAG = "SavedBluetoothDeviceUpdater";
|
||||||
private static final boolean DBG = Log.isLoggable(BluetoothDeviceUpdater.TAG, Log.DEBUG);
|
|
||||||
|
|
||||||
private static final String PREF_KEY = "saved_bt";
|
private static final String PREF_KEY = "saved_bt";
|
||||||
|
|
||||||
@@ -100,11 +99,9 @@ public class SavedBluetoothDeviceUpdater extends BluetoothDeviceUpdater
|
|||||||
@Override
|
@Override
|
||||||
public boolean isFilterMatched(CachedBluetoothDevice cachedDevice) {
|
public boolean isFilterMatched(CachedBluetoothDevice cachedDevice) {
|
||||||
final BluetoothDevice device = cachedDevice.getDevice();
|
final BluetoothDevice device = cachedDevice.getDevice();
|
||||||
if (DBG) {
|
Log.d(TAG, "isFilterMatched() device name : " + cachedDevice.getName() +
|
||||||
Log.d(TAG, "isFilterMatched() device name : " + cachedDevice.getName() +
|
", is connected : " + device.isConnected() + ", is profile connected : "
|
||||||
", is connected : " + device.isConnected() + ", is profile connected : "
|
+ cachedDevice.isConnected());
|
||||||
+ cachedDevice.isConnected());
|
|
||||||
}
|
|
||||||
return device.getBondState() == BluetoothDevice.BOND_BONDED
|
return device.getBondState() == BluetoothDevice.BOND_BONDED
|
||||||
&& (mShowConnectedDevice || (!device.isConnected() && isDeviceInCachedDevicesList(
|
&& (mShowConnectedDevice || (!device.isConnected() && isDeviceInCachedDevicesList(
|
||||||
cachedDevice)));
|
cachedDevice)));
|
||||||
|
Reference in New Issue
Block a user