Merge "Do not set different gravity for non-moveable nav bar" into udc-dev am: 64c27756ba am: 5369328b06 am: 1fee2452ab

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

Change-Id: I471d5998f9fb7bc1e706cde2424f9f62dcdadcc3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Treehugger Robot
2023-05-02 14:33:36 +00:00
committed by Automerger Merge Worker

View File

@@ -359,9 +359,12 @@ class WindowTestsBase extends SystemServiceTestsBase {
new InsetsFrameProvider(owner, 0, WindowInsets.Type.tappableElement()),
new InsetsFrameProvider(owner, 0, WindowInsets.Type.mandatorySystemGestures())
};
for (int rot = Surface.ROTATION_0; rot <= Surface.ROTATION_270; rot++) {
mNavBarWindow.mAttrs.paramsForRotation[rot] =
getNavBarLayoutParamsForRotation(rot, owner);
// If the navigation bar cannot move then it is always at the bottom.
if (mDisplayContent.getDisplayPolicy().navigationBarCanMove()) {
for (int rot = Surface.ROTATION_0; rot <= Surface.ROTATION_270; rot++) {
mNavBarWindow.mAttrs.paramsForRotation[rot] =
getNavBarLayoutParamsForRotation(rot, owner);
}
}
}
if (addAll || ArrayUtils.contains(requestedWindows, W_DOCK_DIVIDER)) {