Loading android/apishim/OWNERS +1 −3 Original line number Diff line number Diff line # Reviewers for /android/apishim cmanton@google.com eruffieux@google.com jpawlowski@google.com mylesgw@google.com siyuanh@google.com wescande@google.com android/app/Android.bp +1 −0 Original line number Diff line number Diff line Loading @@ -342,6 +342,7 @@ android_app { "-Xep:EqualsHashCode:ERROR", "-Xep:FallThrough:ERROR", "-Xep:Finalize:ERROR", "-Xep:GuardedBy:ERROR", "-Xep:HidingField:ERROR", "-Xep:InconsistentHashCode:ERROR", "-Xep:InlineMeInliner:ERROR", Loading android/app/OWNERS +0 −2 Original line number Diff line number Diff line # Reviewers for /android/app bhaktha@google.com cmanton@google.com eruffieux@google.com hallstrom@google.com henrichataing@google.com jpawlowski@google.com mylesgw@google.com okamil@google.com poahlo@google.com siyuanh@google.com Loading android/app/aidl/android/bluetooth/IBluetoothCallback.aidl +2 −1 Original line number Diff line number Diff line Loading @@ -23,6 +23,7 @@ package android.bluetooth; */ interface IBluetoothCallback { //void onRfcommChannelFound(int channel); void onBluetoothStateChange(int prevState, int newState); void onAdapterNameChange(String name); void onAdapterAddressChange(String address); } android/app/src/com/android/bluetooth/a2dp/A2dpService.java +19 −9 Original line number Diff line number Diff line Loading @@ -524,12 +524,14 @@ public class A2dpService extends ProfileService { @VisibleForTesting public boolean setSilenceMode(@NonNull BluetoothDevice device, boolean silence) { Log.d(TAG, "setSilenceMode(" + device + "): " + silence); synchronized (mStateMachines) { if (silence && Objects.equals(mActiveDevice, device)) { removeActiveDevice(true); } else if (!silence && mActiveDevice == null) { // Set the device as the active device if currently no active device. setActiveDevice(device); } } if (!mNativeInterface.setSilenceDevice(device, silence)) { Log.e(TAG, "Cannot set " + device + " silence mode " + silence + " in native layer"); return false; Loading Loading @@ -752,8 +754,10 @@ public class A2dpService extends ProfileService { public void setCodecConfigPreference(BluetoothDevice device, BluetoothCodecConfig codecConfig) { Log.d(TAG, "setCodecConfigPreference(" + device + "): " + Objects.toString(codecConfig)); if (device == null) { synchronized (mStateMachines) { device = mActiveDevice; } } if (device == null) { Log.e(TAG, "setCodecConfigPreference: Invalid device"); return; Loading @@ -779,8 +783,10 @@ public class A2dpService extends ProfileService { public void enableOptionalCodecs(BluetoothDevice device) { Log.d(TAG, "enableOptionalCodecs(" + device + ")"); if (device == null) { synchronized (mStateMachines) { device = mActiveDevice; } } if (device == null) { Log.e(TAG, "enableOptionalCodecs: Invalid device"); return; Loading @@ -807,8 +813,10 @@ public class A2dpService extends ProfileService { public void disableOptionalCodecs(BluetoothDevice device) { Log.d(TAG, "disableOptionalCodecs(" + device + ")"); if (device == null) { synchronized (mStateMachines) { device = mActiveDevice; } } if (device == null) { Log.e(TAG, "disableOptionalCodecs: Invalid device"); return; Loading Loading @@ -1685,7 +1693,9 @@ public class A2dpService extends ProfileService { @Override public void dump(StringBuilder sb) { super.dump(sb); synchronized (mStateMachines) { ProfileService.println(sb, "mActiveDevice: " + mActiveDevice); } ProfileService.println(sb, "mMaxConnectedAudioDevices: " + mMaxConnectedAudioDevices); if (mA2dpCodecConfig != null) { ProfileService.println(sb, "codecConfigPriorities:"); Loading Loading
android/apishim/OWNERS +1 −3 Original line number Diff line number Diff line # Reviewers for /android/apishim cmanton@google.com eruffieux@google.com jpawlowski@google.com mylesgw@google.com siyuanh@google.com wescande@google.com
android/app/Android.bp +1 −0 Original line number Diff line number Diff line Loading @@ -342,6 +342,7 @@ android_app { "-Xep:EqualsHashCode:ERROR", "-Xep:FallThrough:ERROR", "-Xep:Finalize:ERROR", "-Xep:GuardedBy:ERROR", "-Xep:HidingField:ERROR", "-Xep:InconsistentHashCode:ERROR", "-Xep:InlineMeInliner:ERROR", Loading
android/app/OWNERS +0 −2 Original line number Diff line number Diff line # Reviewers for /android/app bhaktha@google.com cmanton@google.com eruffieux@google.com hallstrom@google.com henrichataing@google.com jpawlowski@google.com mylesgw@google.com okamil@google.com poahlo@google.com siyuanh@google.com Loading
android/app/aidl/android/bluetooth/IBluetoothCallback.aidl +2 −1 Original line number Diff line number Diff line Loading @@ -23,6 +23,7 @@ package android.bluetooth; */ interface IBluetoothCallback { //void onRfcommChannelFound(int channel); void onBluetoothStateChange(int prevState, int newState); void onAdapterNameChange(String name); void onAdapterAddressChange(String address); }
android/app/src/com/android/bluetooth/a2dp/A2dpService.java +19 −9 Original line number Diff line number Diff line Loading @@ -524,12 +524,14 @@ public class A2dpService extends ProfileService { @VisibleForTesting public boolean setSilenceMode(@NonNull BluetoothDevice device, boolean silence) { Log.d(TAG, "setSilenceMode(" + device + "): " + silence); synchronized (mStateMachines) { if (silence && Objects.equals(mActiveDevice, device)) { removeActiveDevice(true); } else if (!silence && mActiveDevice == null) { // Set the device as the active device if currently no active device. setActiveDevice(device); } } if (!mNativeInterface.setSilenceDevice(device, silence)) { Log.e(TAG, "Cannot set " + device + " silence mode " + silence + " in native layer"); return false; Loading Loading @@ -752,8 +754,10 @@ public class A2dpService extends ProfileService { public void setCodecConfigPreference(BluetoothDevice device, BluetoothCodecConfig codecConfig) { Log.d(TAG, "setCodecConfigPreference(" + device + "): " + Objects.toString(codecConfig)); if (device == null) { synchronized (mStateMachines) { device = mActiveDevice; } } if (device == null) { Log.e(TAG, "setCodecConfigPreference: Invalid device"); return; Loading @@ -779,8 +783,10 @@ public class A2dpService extends ProfileService { public void enableOptionalCodecs(BluetoothDevice device) { Log.d(TAG, "enableOptionalCodecs(" + device + ")"); if (device == null) { synchronized (mStateMachines) { device = mActiveDevice; } } if (device == null) { Log.e(TAG, "enableOptionalCodecs: Invalid device"); return; Loading @@ -807,8 +813,10 @@ public class A2dpService extends ProfileService { public void disableOptionalCodecs(BluetoothDevice device) { Log.d(TAG, "disableOptionalCodecs(" + device + ")"); if (device == null) { synchronized (mStateMachines) { device = mActiveDevice; } } if (device == null) { Log.e(TAG, "disableOptionalCodecs: Invalid device"); return; Loading Loading @@ -1685,7 +1693,9 @@ public class A2dpService extends ProfileService { @Override public void dump(StringBuilder sb) { super.dump(sb); synchronized (mStateMachines) { ProfileService.println(sb, "mActiveDevice: " + mActiveDevice); } ProfileService.println(sb, "mMaxConnectedAudioDevices: " + mMaxConnectedAudioDevices); if (mA2dpCodecConfig != null) { ProfileService.println(sb, "codecConfigPriorities:"); Loading