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

Commit 43e2a2b2 authored by Riddle Hsu's avatar Riddle Hsu Committed by Automerger Merge Worker
Browse files

Set fit insets type for decor insets test am: 614ed9e0

parents bed60a72 614ed9e0
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -362,10 +362,12 @@ public class DisplayPolicyTests extends WindowTestsBase {
                new InsetsFrameProvider(bar2, 0, WindowInsets.Type.statusBars())
                        .setInsetsSize(Insets.of(0, STATUS_BAR_HEIGHT, 0, 0))
        };
        bar2.mAttrs.setFitInsetsTypes(0);
        bar2.mAttrs.paramsForRotation = new WindowManager.LayoutParams[4];
        final int doubleHeightFor90 = STATUS_BAR_HEIGHT * 2;
        for (int i = ROTATION_0; i <= Surface.ROTATION_270; i++) {
            final WindowManager.LayoutParams params = new WindowManager.LayoutParams();
            params.setFitInsetsTypes(0);
            if (i == Surface.ROTATION_90) {
                params.providedInsets = new InsetsFrameProvider[] {
                        new InsetsFrameProvider(bar2, 0, WindowInsets.Type.statusBars())
+1 −0
Original line number Diff line number Diff line
@@ -485,6 +485,7 @@ class WindowTestsBase extends SystemServiceTestsBase {
                new InsetsFrameProvider(owner, 0, WindowInsets.Type.statusBars())
                        .setInsetsSize(Insets.of(0, STATUS_BAR_HEIGHT, 0, 0))
        };
        statusBar.mAttrs.setFitInsetsTypes(0);
        dc.getDisplayPolicy().addWindowLw(statusBar, statusBar.mAttrs);
        return statusBar;
    }