Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 348f6262 authored by More Kuo's avatar More Kuo Committed by Automerger Merge Worker
Browse files

Merge "Update BluetoothA2dp API" am: 23be8f3f am: a6b501e1 am: 53c61154

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1596413

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I234ca0e0c123293a56516e1ed461bfbd9f5b1481
parents 8de5fd90 53c61154
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -943,12 +943,13 @@ public final class BluetoothA2dp implements BluetoothProfile {
     */
    @SystemApi
    @RequiresPermission(Manifest.permission.BLUETOOTH_PRIVILEGED)
    public boolean setBufferMillis(@BluetoothCodecConfig.SourceCodecType int codec, int value) {
        if (VDBG) log("setBufferMillis(" + codec + ", " + value + ")");
    public boolean setBufferLengthMillis(@BluetoothCodecConfig.SourceCodecType int codec,
            int value) {
        if (VDBG) log("setBufferLengthMillis(" + codec + ", " + value + ")");
        try {
            final IBluetoothA2dp service = getService();
            if (service != null && isEnabled()) {
                return service.setBufferMillis(codec, value);
                return service.setBufferLengthMillis(codec, value);
            }
            if (service == null) Log.w(TAG, "Proxy not attached to service");
            return false;
+1 −1
Original line number Diff line number Diff line
@@ -90,7 +90,7 @@ public final class BufferConstraints implements Parcelable {
     * @hide
     */
    @SystemApi
    public @Nullable BufferConstraint getCodec(@BluetoothCodecConfig.SourceCodecType int codec) {
    public @Nullable BufferConstraint forCodec(@BluetoothCodecConfig.SourceCodecType int codec) {
        return mBufferConstraints.get(codec);
    }
}