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

Commit c84dca14 authored by wilsonshih's avatar wilsonshih
Browse files

Polish non-main app window flashing under starting window.

Skip playing entering animation for non-main app window if starting
window existing, the enter animation can shift window position, so
it may seems blured during fade-out snapshot starting window.

Preventing from apply dim layer for starting window, the dim layer
should be used for other app window, but it is impossible to place
under starting window.

Bug: 321874837
Test: follow issue description, launch app from home several times.
Change-Id: I1b5bf7ae33fd19f7cf37d38902aab41ffb5b10f5
parent d873062c
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -21,6 +21,7 @@ import static android.graphics.Color.alpha;
import static android.view.WindowInsetsController.APPEARANCE_LIGHT_NAVIGATION_BARS;
import static android.view.WindowInsetsController.APPEARANCE_LIGHT_STATUS_BARS;
import static android.view.WindowManager.LayoutParams.FLAG_ALT_FOCUSABLE_IM;
import static android.view.WindowManager.LayoutParams.FLAG_DIM_BEHIND;
import static android.view.WindowManager.LayoutParams.FLAG_HARDWARE_ACCELERATED;
import static android.view.WindowManager.LayoutParams.FLAG_IGNORE_CHEEK_PRESSES;
import static android.view.WindowManager.LayoutParams.FLAG_LOCAL_FOCUS_MODE;
@@ -93,7 +94,8 @@ public class SnapshotDrawerUtils {
            | FLAG_WATCH_OUTSIDE_TOUCH
            | FLAG_SPLIT_TOUCH
            | FLAG_SCALED
            | FLAG_SECURE;
            | FLAG_SECURE
            | FLAG_DIM_BEHIND;

    private static final RectF sTmpSnapshotSize = new RectF();
    private static final RectF sTmpDstFrame = new RectF();
+4 −0
Original line number Diff line number Diff line
@@ -499,6 +499,10 @@ class WindowStateAnimator {
    }

    void applyEnterAnimationLocked() {
        if (mWin.mActivityRecord != null && mWin.mActivityRecord.hasStartingWindow()) {
            // It's unnecessary to play enter animation below starting window.
            return;
        }
        final int transit;
        if (mEnterAnimationPending) {
            mEnterAnimationPending = false;