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

Commit d3ae2202 authored by Craig Mautner's avatar Craig Mautner Committed by Android (Google) Code Review
Browse files

Merge "Fix flickering when starting and ending apps."

parents 0b83efb6 22ce1414
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -135,6 +135,10 @@ class AppWindowToken extends WindowToken {
            animLayerAdjustment = adj;
            updateLayers();
        }
        // Start out animation gone if window is gone, or visible if window is visible.
        transformation.clear();
        transformation.setAlpha(reportedVisible ? 1 : 0);
        hasTransformation = true;
    }

    public void setDummyAnimation() {
+0 −1
Original line number Diff line number Diff line
@@ -8675,7 +8675,6 @@ public class WindowManagerService extends IWindowManager.Stub
                    } else {
                        mDimAnimator.show(innerDw, innerDh);
                    }
                    mDimAnimator.show(innerDw, innerDh);
                    mDimAnimator.updateParameters(mContext.getResources(),
                            w, currentTime);
                }
+9 −3
Original line number Diff line number Diff line
@@ -640,6 +640,10 @@ final class WindowState implements WindowManagerPolicy.WindowState {
        mAnimation = anim;
        mAnimation.restrictDuration(WindowManagerService.MAX_ANIMATION_DURATION);
        mAnimation.scaleCurrentDuration(mService.mWindowAnimationScale);
        // Start out animation gone if window is gone, or visible if window is visible.
        mTransformation.clear();
        mTransformation.setAlpha(mLastHidden ? 0 : 1);
        mHasLocalTransformation = true;
    }

    public void clearAnimation() {
@@ -933,13 +937,15 @@ final class WindowState implements WindowManagerPolicy.WindowState {
            if (!mService.showSurfaceRobustlyLocked(this)) {
                return false;
            }
            
            mService.enableScreenIfNeededLocked();

            mService.applyEnterAnimationLocked(this);

            mLastAlpha = -1;
            mHasDrawn = true;
            mLastHidden = false;
            mReadyToShow = false;
            mService.enableScreenIfNeededLocked();

            mService.applyEnterAnimationLocked(this);

            int i = mChildWindows.size();
            while (i > 0) {