mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-20 11:18:21 +00:00
Don't apply nav bar insets in tablets
- With flexible inset changes in T, taskbar is no longer inseted in getCurrentSizeRange, i.e. DeviceProfile.availableHeight no longer inset nav bar size - In order for home screen sizes to be calcualted correctly, avoid inseting nav bar in LauncherRootView - Only apply a bottom padding with stashed taskbar size to necessarily surfaces (Overview) - Home screen icon overlap will be fixed in separate CL Bug: 215528237 Test: maual in tablet gesture nav and 3 buttons Change-Id: I9bc796ba059159e819f8cd121ddabab96c8113d2
This commit is contained in:
@@ -105,8 +105,9 @@ public class LauncherRootView extends InsettableFrameLayout {
|
||||
resources,
|
||||
INVALID_RESOURCE_HANDLE) == 2;
|
||||
if (dp.isTablet || isGesturalMode) {
|
||||
newNavInsets.bottom = ResourceUtils.getNavbarSize(
|
||||
"navigation_bar_height_landscape", resources);
|
||||
newNavInsets.bottom = dp.isTaskbarPresent
|
||||
? 0
|
||||
: ResourceUtils.getNavbarSize("navigation_bar_height_landscape", resources);
|
||||
} else {
|
||||
int navWidth = ResourceUtils.getNavbarSize("navigation_bar_width", resources);
|
||||
if (dp.isSeascape()) {
|
||||
@@ -116,7 +117,9 @@ public class LauncherRootView extends InsettableFrameLayout {
|
||||
}
|
||||
}
|
||||
} else {
|
||||
newNavInsets.bottom = ResourceUtils.getNavbarSize("navigation_bar_height", resources);
|
||||
newNavInsets.bottom = dp.isTaskbarPresent
|
||||
? 0
|
||||
: ResourceUtils.getNavbarSize("navigation_bar_height", resources);
|
||||
}
|
||||
updatedInsetsBuilder.setInsets(WindowInsets.Type.navigationBars(), Insets.of(newNavInsets));
|
||||
updatedInsetsBuilder.setInsetsIgnoringVisibility(WindowInsets.Type.navigationBars(),
|
||||
|
||||
Reference in New Issue
Block a user