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

Commit ab648b81 authored by Android Build Coastguard Worker's avatar Android Build Coastguard Worker
Browse files

Merge cherrypicks of ['googleplex-android-review.googlesource.com/23765883',...

Merge cherrypicks of ['googleplex-android-review.googlesource.com/23765883', 'googleplex-android-review.googlesource.com/23810764'] into udc-release.

Change-Id: I17162ee23ca898e5c3418237e31d353984322195
parents 633b16d7 060c6919
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -2666,7 +2666,10 @@ class Transition implements BLASTSyncEngine.TransactionReadyListener {
        mController.mStateValidators.add(() -> {
            for (int i = mTargets.size() - 1; i >= 0; --i) {
                final ChangeInfo change = mTargets.get(i);
                if (!change.mContainer.isVisibleRequested()) continue;
                if (!change.mContainer.isVisibleRequested()
                        || change.mContainer.mSurfaceControl == null) {
                    continue;
                }
                Slog.e(TAG, "Force show for visible " + change.mContainer
                        + " which may be hidden by transition unexpectedly");
                change.mContainer.getSyncTransaction().show(change.mContainer.mSurfaceControl);
+10 −2
Original line number Diff line number Diff line
@@ -59,6 +59,8 @@ public final class UsbAlsaDevice {
    private String mDeviceName = "";
    private String mDeviceDescription = "";

    private boolean mHasJackDetect = true;

    public UsbAlsaDevice(IAudioService audioService, int card, int device, String deviceAddress,
            boolean hasOutput, boolean hasInput,
            boolean isInputHeadset, boolean isOutputHeadset, boolean isDock) {
@@ -168,8 +170,14 @@ public final class UsbAlsaDevice {
        if (mJackDetector != null) {
            return;
        }
        if (!mHasJackDetect) {
            return;
        }
        // If no jack detect capabilities exist, mJackDetector will be null.
        mJackDetector = UsbAlsaJackDetector.startJackDetect(this);
        if (mJackDetector == null) {
            mHasJackDetect = false;
        }
    }

    /** Stops a jack-detection thread. */
@@ -182,8 +190,8 @@ public final class UsbAlsaDevice {

    /** Start using this device as the selected USB Audio Device. */
    public synchronized void start() {
        startInput();
        startOutput();
        startInput();
    }

    /** Start using this device as the selected USB input device. */
@@ -208,8 +216,8 @@ public final class UsbAlsaDevice {

    /** Stop using this device as the selected USB Audio Device. */
    public synchronized void stop() {
        stopInput();
        stopOutput();
        stopInput();
    }

    /** Stop using this device as the selected USB input device. */