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

Commit 08e5d43e authored by SongFerng Wang's avatar SongFerng Wang Committed by Automerger Merge Worker
Browse files

Merge "[LE adudio] The condition of right location is wrong." am: 75869b5f...

Merge "[LE adudio] The condition of right location is wrong." am: 75869b5f am: 285952a8 am: eefaf62b

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

Change-Id: I1a191387a358a40da753539284bba70d050a9bcd
parents 240e85be eefaf62b
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -275,11 +275,15 @@ public class LeAudioBluetoothDetailsHeaderController extends BasePreferenceContr
                return;
            }
            boolean isLeft = (deviceId & LEFT_DEVICE_ID) != 0;
            boolean isRight = (deviceId & LEFT_DEVICE_ID) != 0;
            boolean isRight = (deviceId & RIGHT_DEVICE_ID) != 0;
            boolean isLeftRight = isLeft && isRight;
            // The LE device updates the BatteryLayout
            if (isLeftRight) {
                Log.d(TAG, "The device id is left+right. Do nothing.");
                Log.d(TAG, "Show the legacy battery style if the device id is left+right.");
                final TextView summary = mLayoutPreference.findViewById(R.id.entity_header_summary);
                if (summary != null) {
                    summary.setText(mCachedDevice.getConnectionSummary());
                }
            } else if (isLeft) {
                updateBatteryLayout(getBatteryTitleResource(LEFT_DEVICE_ID),
                        getBatterySummaryResource(LEFT_DEVICE_ID), cachedDevice.getBatteryLevel());