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

Commit 95acf43c authored by Lucas Dupin's avatar Lucas Dupin
Browse files

Disable rounded corners when in multi window

We should not draw rounded corners when animating windows into split
view. The divider is a single horizontal line, and we don't support
multiple radii per window.

Fixes: 129540518
Test: visual
Change-Id: Ic31395c77f376053a136a9c55382b74b4157ee34
Merged-In: Ic31395c77f376053a136a9c55382b74b4157ee34
parent 50e31711
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -2553,12 +2553,17 @@ class AppWindowToken extends WindowToken implements WindowManagerService.AppFree

                final Animation a = loadAnimation(lp, transit, enter, isVoiceInteraction);
                if (a != null) {
                    // Only apply corner radius to animation if we're not in multi window mode.
                    // We don't want rounded corners when in pip or split screen.
                    final float windowCornerRadius = !inMultiWindowMode()
                            ? getDisplayContent().getWindowCornerRadius()
                            : 0;
                    adapter = new LocalAnimationAdapter(
                            new WindowAnimationSpec(a, mTmpPoint, mTmpRect,
                                    getDisplayContent().mAppTransition.canSkipFirstFrame(),
                                    appStackClipMode,
                                    true /* isAppAnimation */,
                                    getDisplayContent().getWindowCornerRadius()),
                                    windowCornerRadius),
                            mWmService.mSurfaceAnimationRunner);
                    if (a.getZAdjustment() == Animation.ZORDER_TOP) {
                        mNeedsZBoost = true;
+1 −1
Original line number Diff line number Diff line
@@ -4599,7 +4599,7 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP
        anim.scaleCurrentDuration(mWmService.getWindowAnimationScaleLocked());
        final AnimationAdapter adapter = new LocalAnimationAdapter(
                new WindowAnimationSpec(anim, mSurfacePosition, false /* canSkipFirstFrame */,
                        getDisplayContent().getWindowCornerRadius()),
                        0 /* windowCornerRadius */),
                mWmService.mSurfaceAnimationRunner);
        startAnimation(mPendingTransaction, adapter);
        commitPendingTransaction();