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

Commit 8635c449 authored by Lucas Dupin's avatar Lucas Dupin
Browse files

Fix issue with transition cancelling

Fixes: 69901116
Fixes: 70296214
Test: Double tap power button to launch camera
Test: Unlock with fingerprint, pin, SmartLock
Test: Unlock with fingerprint while changing brightness
Test: Unlock by tapping notification
Change-Id: I487b29c3aa5460cbd120072becb4e0449cffcce6
parent c51ec676
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -204,12 +204,15 @@ public class ScrimController implements ViewTreeObserver.OnPreDrawListener,
            throw new IllegalArgumentException("Cannot change to UNINITIALIZED.");
        }

        final ScrimState oldState = mState;
        mState = state;

        if (mCallback != null) {
            mCallback.onCancelled();
        }
        mCallback = callback;

        state.prepare(mState);
        state.prepare(oldState);
        mScreenBlankingCallbackCalled = false;
        mAnimationDelay = 0;
        mBlankScreen = state.getBlanksScreen();
@@ -228,8 +231,6 @@ public class ScrimController implements ViewTreeObserver.OnPreDrawListener,
            mKeyguardFadeoutAnimation.cancel();
        }

        mState = state;

        // Do not let the device sleep until we're done with all animations
        if (!mWakeLockHeld) {
            if (mWakeLock != null) {
@@ -310,7 +311,6 @@ public class ScrimController implements ViewTreeObserver.OnPreDrawListener,
                    mCurrentInFrontAlpha = 0;
                }
            } else {
                Log.w(TAG, "Invalid state, cannot set panel expansion when: " + mState);
                return;
            }

+1 −2
Original line number Diff line number Diff line
@@ -659,8 +659,7 @@ public class StatusBar extends SystemUI implements DemoMode,

        @Override
        public void onCancelled() {
            // Transition was cancelled because another one took over.
            // Nothing to do in here but wait.
            onFinished();
        }
    };