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

Commit 4dee16ab authored by Yunfan Chen's avatar Yunfan Chen Committed by Automerger Merge Worker
Browse files

Merge "Do not override insets frame if not set" into tm-dev am: bfa7c5d2 am:...

Merge "Do not override insets frame if not set" into tm-dev am: bfa7c5d2 am: 08d79c8f am: 04ded0be

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18331263



Change-Id: Icfc769a3087a3ce39092d4cc3a4864601cfcf927
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents af667e47 04ded0be
Loading
Loading
Loading
Loading
+15 −13
Original line number Diff line number Diff line
@@ -1206,7 +1206,8 @@ public class DisplayPolicy {
                if (attrs.providesInsetsTypes != null) {
                    for (@InternalInsetsType int insetsType : attrs.providesInsetsTypes) {
                        final TriConsumer<DisplayFrames, WindowContainer, Rect> imeFrameProvider =
                                (displayFrames, windowContainer, inOutFrame) -> {
                                win.getAttrs().providedInternalImeInsets != null
                                        ? (displayFrames, windowContainer, inOutFrame) -> {
                                    final Insets[] providedInternalImeInsets =
                                            win.getLayoutingAttrs(displayFrames.mRotation)
                                                    .providedInternalImeInsets;
@@ -1215,7 +1216,7 @@ public class DisplayPolicy {
                                            && providedInternalImeInsets[insetsType] != null) {
                                        inOutFrame.inset(providedInternalImeInsets[insetsType]);
                                    }
                                };
                                } : null;
                        switch (insetsType) {
                            case ITYPE_STATUS_BAR:
                                mStatusBarAlt = win;
@@ -1234,7 +1235,8 @@ public class DisplayPolicy {
                                mExtraNavBarAltPosition = getAltBarPosition(attrs);
                                break;
                        }
                        mDisplayContent.setInsetProvider(insetsType, win, (displayFrames,
                        mDisplayContent.setInsetProvider(insetsType, win,
                                win.getAttrs().providedInternalInsets != null ? (displayFrames,
                                        windowContainer, inOutFrame) -> {
                                    final Insets[] providedInternalInsets = win.getLayoutingAttrs(
                                            displayFrames.mRotation).providedInternalInsets;
@@ -1244,7 +1246,7 @@ public class DisplayPolicy {
                                        inOutFrame.inset(providedInternalInsets[insetsType]);
                                    }
                                    inOutFrame.inset(win.mGivenContentInsets);
                        }, imeFrameProvider);
                                } : null, imeFrameProvider);
                        mInsetsSourceWindowsExceptIme.add(win);
                    }
                }