summaryrefslogtreecommitdiff
path: root/core/java
diff options
context:
space:
mode:
authorSam Dubey <dubeyshubham@google.com>2022-07-15 12:22:44 +0000
committerSam Dubey <dubeyshubham@google.com>2022-07-15 12:22:44 +0000
commitbc0d5539e6ce80bb686dd38f6517f9c2dcd77aa0 (patch)
tree5c84fad9bd9f79cb7cc55992ceccf4c03d65d8f5 /core/java
parent620e91578cb5d0bbfbf6f8c5aedb77e23c13ef49 (diff)
Revert "Reland "Make extra navigation bar count towards non decor frame"""
This reverts commit 620e91578cb5d0bbfbf6f8c5aedb77e23c13ef49. Reason for revert: b/238985243 Change-Id: I1fc82c61b445b6f5ceedb2ec8b727e8e745f47c9
Diffstat (limited to 'core/java')
-rw-r--r--core/java/android/view/WindowLayout.java18
1 files changed, 9 insertions, 9 deletions
diff --git a/core/java/android/view/WindowLayout.java b/core/java/android/view/WindowLayout.java
index 5ed9d2f90a72..57a0330e3c18 100644
--- a/core/java/android/view/WindowLayout.java
+++ b/core/java/android/view/WindowLayout.java
@@ -118,11 +118,11 @@ public class WindowLayout {
}
if (cutoutMode == LAYOUT_IN_DISPLAY_CUTOUT_MODE_SHORT_EDGES) {
if (displayFrame.width() < displayFrame.height()) {
- displayCutoutSafeExceptMaybeBars.top = MIN_Y;
- displayCutoutSafeExceptMaybeBars.bottom = MAX_Y;
+ displayCutoutSafeExceptMaybeBars.top = Integer.MIN_VALUE;
+ displayCutoutSafeExceptMaybeBars.bottom = Integer.MAX_VALUE;
} else {
- displayCutoutSafeExceptMaybeBars.left = MIN_X;
- displayCutoutSafeExceptMaybeBars.right = MAX_X;
+ displayCutoutSafeExceptMaybeBars.left = Integer.MIN_VALUE;
+ displayCutoutSafeExceptMaybeBars.right = Integer.MAX_VALUE;
}
}
final boolean layoutInsetDecor = (attrs.flags & FLAG_LAYOUT_INSET_DECOR) != 0;
@@ -132,23 +132,23 @@ public class WindowLayout {
final Insets systemBarsInsets = state.calculateInsets(
displayFrame, WindowInsets.Type.systemBars(), requestedVisibilities);
if (systemBarsInsets.left > 0) {
- displayCutoutSafeExceptMaybeBars.left = MIN_X;
+ displayCutoutSafeExceptMaybeBars.left = Integer.MIN_VALUE;
}
if (systemBarsInsets.top > 0) {
- displayCutoutSafeExceptMaybeBars.top = MIN_Y;
+ displayCutoutSafeExceptMaybeBars.top = Integer.MIN_VALUE;
}
if (systemBarsInsets.right > 0) {
- displayCutoutSafeExceptMaybeBars.right = MAX_X;
+ displayCutoutSafeExceptMaybeBars.right = Integer.MAX_VALUE;
}
if (systemBarsInsets.bottom > 0) {
- displayCutoutSafeExceptMaybeBars.bottom = MAX_Y;
+ displayCutoutSafeExceptMaybeBars.bottom = Integer.MAX_VALUE;
}
}
if (type == TYPE_INPUT_METHOD) {
final InsetsSource navSource = state.peekSource(ITYPE_NAVIGATION_BAR);
if (navSource != null && navSource.calculateInsets(displayFrame, true).bottom > 0) {
// The IME can always extend under the bottom cutout if the navbar is there.
- displayCutoutSafeExceptMaybeBars.bottom = MAX_Y;
+ displayCutoutSafeExceptMaybeBars.bottom = Integer.MAX_VALUE;
}
}
final boolean attachedInParent = attachedWindowFrame != null && !layoutInScreen;