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

Commit d47ad033 authored by Adrian Roos's avatar Adrian Roos
Browse files

Fix bars jumping to black on activity launch

During animations, the wallpaper crop is the
union of the start and end crop. This prevents
the system bars from jumping to black when an
activity with opaque bars is launched.

Bug: 16441036
Change-Id: Ic0f3bc2e83b9830514a3456a27ae6f23716f3240
parent 95d9ad0f
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1211,6 +1211,12 @@ class WindowStateAnimator {
                || w.mDecorFrame.isEmpty()) {
            // The universe background isn't cropped, nor windows without policy decor.
            w.mSystemDecorRect.set(0, 0, w.mCompatFrame.width(), w.mCompatFrame.height());
        } else if (w.mAttrs.type == LayoutParams.TYPE_WALLPAPER && mAnimator.mAnimating) {
            // If we're animating, the wallpaper crop should only be updated at the end of the
            // animation.
            mTmpClipRect.set(w.mSystemDecorRect);
            applyDecorRect(w.mDecorFrame);
            w.mSystemDecorRect.union(mTmpClipRect);
        } else {
            // Crop to the system decor specified by policy.
            applyDecorRect(w.mDecorFrame);