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

Commit a4c84173 authored by Perry Wu's avatar Perry Wu
Browse files

Add null check for pending DisplayLayout on insetsChanged

As title says. Added to fix a NPE for pending DipsplayLayout.

Bug: b/357316818
Flag: EXEMPT bugfix
Test: N/A, unknown repro
Change-Id: I1e13db6d4c07408b3594ab33bc878834d68128e7
parent c7e9cca6
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -632,6 +632,12 @@ public class PipController implements PipTransitionController.PipTransitionCallb
                    public void insetsChanged(InsetsState insetsState) {
                        DisplayLayout pendingLayout = mDisplayController
                                .getDisplayLayout(mPipDisplayLayoutState.getDisplayId());
                        if (pendingLayout == null) {
                            ProtoLog.d(ShellProtoLogGroup.WM_SHELL_PICTURE_IN_PICTURE,
                                    "insetsChanged: no display layout for displayId=%d",
                                    mPipDisplayLayoutState.getDisplayId());
                            return;
                        }
                        if (mIsInFixedRotation
                                || mIsKeyguardShowingOrAnimating
                                || pendingLayout.rotation()