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

Commit 5fc16d47 authored by Jakub Pawlowski's avatar Jakub Pawlowski Committed by Automerger Merge Worker
Browse files

Merge "AdapterProperties: Extend with new local features" am: 6914d196

Original change: https://android-review.googlesource.com/c/platform/packages/apps/Bluetooth/+/1830241

Change-Id: I8770823f23a6ca59ce8d43495b81576b02b0d015
parents aea67d4b 6914d196
Loading
Loading
Loading
Loading
+25 −1
Original line number Diff line number Diff line
@@ -125,6 +125,10 @@ class AdapterProperties {
    private int mIsDynamicAudioBufferSizeSupported;
    private int mDynamicAudioBufferSizeSupportedCodecsGroup1;
    private int mDynamicAudioBufferSizeSupportedCodecsGroup2;

    private boolean mIsLePeriodicAdvertisingSyncTransferSenderSupported;
    private boolean mIsLeConnectedIsochronousStreamCentralSupported;

    private List<BufferConstraint> mBufferConstraintList;

    private boolean mReceiverRegistered;
@@ -500,6 +504,20 @@ class AdapterProperties {
        return mIsLePeriodicAdvertisingSupported;
    }

    /**
     * @return the mIsLePeriodicAdvertisingSyncTransferSenderSupported
     */
    boolean isLePeriodicAdvertisingSyncTransferSenderSupported() {
        return mIsLePeriodicAdvertisingSyncTransferSenderSupported;
    }

    /**
     * @return the mIsLeConnectedIsochronousStreamCentralSupported
     */
    boolean isLeConnectedIsochronousStreamCentralSupported() {
        return mIsLeConnectedIsochronousStreamCentralSupported;
    }

    /**
     * @return the getLeMaximumAdvertisingDataLength
     */
@@ -957,6 +975,8 @@ class AdapterProperties {
                ((0xFF & ((int) val[21])) << 8) + (0xFF & ((int) val[20]));
        mDynamicAudioBufferSizeSupportedCodecsGroup2 =
                ((0xFF & ((int) val[23])) << 8) + (0xFF & ((int) val[22]));
        mIsLePeriodicAdvertisingSyncTransferSenderSupported = ((0xFF & ((int) val[24])) != 0);
        mIsLeConnectedIsochronousStreamCentralSupported = ((0xFF & ((int) val[25])) != 0);

        Log.d(TAG, "BT_PROPERTY_LOCAL_LE_FEATURES: update from BT controller"
                + " mNumOfAdvertisementInstancesSupported = "
@@ -976,7 +996,11 @@ class AdapterProperties {
                + " mDynamicAudioBufferSizeSupportedCodecsGroup1 = "
                + mDynamicAudioBufferSizeSupportedCodecsGroup1
                + " mDynamicAudioBufferSizeSupportedCodecsGroup2 = "
                + mDynamicAudioBufferSizeSupportedCodecsGroup2);
                + mDynamicAudioBufferSizeSupportedCodecsGroup2
                + " mIsLePeriodicAdvertisingSyncTransferSenderSupported = "
                + mIsLePeriodicAdvertisingSyncTransferSenderSupported
                + " mIsLeConnectedIsochronousStreamCentralSupported = "
                + mIsLeConnectedIsochronousStreamCentralSupported);
        invalidateIsOffloadedFilteringSupportedCache();
    }

+8 −0
Original line number Diff line number Diff line
@@ -3236,6 +3236,14 @@ public class AdapterService extends Service {
        return mAdapterProperties.getLeMaximumAdvertisingDataLength();
    }

    public boolean isLePeriodicAdvertisingSyncTransferSenderSupported() {
        return mAdapterProperties.isLePeriodicAdvertisingSyncTransferSenderSupported();
    }

    public boolean isLeConnectedIsochronousStreamCentralSupported() {
        return mAdapterProperties.isLeConnectedIsochronousStreamCentralSupported();
    }

    /**
     * Get the maximum number of connected audio devices.
     *