Merge "Use taskbarSize as bottom inset when taskbar is present." into sc-dev

This commit is contained in:
Tony Wickham
2021-03-19 18:15:52 +00:00
committed by Android (Google) Code Review
2 changed files with 3 additions and 3 deletions
@@ -472,7 +472,7 @@ public class TaskbarController {
public void alignRealHotseatWithTaskbar() { public void alignRealHotseatWithTaskbar() {
Rect hotseatBounds = new Rect(); Rect hotseatBounds = new Rect();
DeviceProfile grid = mLauncher.getDeviceProfile(); DeviceProfile grid = mLauncher.getDeviceProfile();
int hotseatHeight = grid.workspacePadding.bottom + grid.getInsets().bottom; int hotseatHeight = grid.workspacePadding.bottom + grid.taskbarSize;
int hotseatTopDiff = hotseatHeight - grid.taskbarSize; int hotseatTopDiff = hotseatHeight - grid.taskbarSize;
mTaskbarView.getHotseatBoundsAtScale(getTaskbarScaleOnHome()).roundOut(hotseatBounds); mTaskbarView.getHotseatBoundsAtScale(getTaskbarScaleOnHome()).roundOut(hotseatBounds);
+2 -2
View File
@@ -122,7 +122,7 @@ public class Hotseat extends CellLayout implements Insettable {
lp.height = (grid.isTaskbarPresent lp.height = (grid.isTaskbarPresent
? grid.workspacePadding.bottom ? grid.workspacePadding.bottom
: grid.hotseatBarSizePx) : grid.hotseatBarSizePx)
+ insets.bottom; + (grid.isTaskbarPresent ? grid.taskbarSize : insets.bottom);
} }
if (!grid.isTaskbarPresent) { if (!grid.isTaskbarPresent) {
@@ -209,7 +209,7 @@ public class Hotseat extends CellLayout implements Insettable {
: dp.hotseatBarSizePx - dp.hotseatCellHeightPx - mQsbHeight; : dp.hotseatBarSizePx - dp.hotseatCellHeightPx - mQsbHeight;
int bottom = b - t int bottom = b - t
- (int) (freeSpace * QSB_CENTER_FACTOR) - (int) (freeSpace * QSB_CENTER_FACTOR)
- dp.getInsets().bottom; - (dp.isTaskbarPresent ? dp.taskbarSize : dp.getInsets().bottom);
int top = bottom - mQsbHeight; int top = bottom - mQsbHeight;
mQsb.layout(left, top, right, bottom); mQsb.layout(left, top, right, bottom);
} }