diff --git a/quickstep/src/com/android/launcher3/taskbar/allapps/TaskbarAllAppsController.java b/quickstep/src/com/android/launcher3/taskbar/allapps/TaskbarAllAppsController.java index 7ada818860..435a0f6efc 100644 --- a/quickstep/src/com/android/launcher3/taskbar/allapps/TaskbarAllAppsController.java +++ b/quickstep/src/com/android/launcher3/taskbar/allapps/TaskbarAllAppsController.java @@ -17,7 +17,9 @@ package com.android.launcher3.taskbar.allapps; import static com.android.launcher3.model.data.AppInfo.EMPTY_ARRAY; +import android.view.Gravity; import android.view.View; +import android.window.DesktopExperienceFlags; import androidx.annotation.NonNull; import androidx.annotation.Nullable; @@ -31,6 +33,7 @@ import com.android.launcher3.model.data.ItemInfo; import com.android.launcher3.taskbar.TaskbarControllers; import com.android.launcher3.taskbar.overlay.TaskbarOverlayContext; import com.android.launcher3.util.PackageUserKey; +import com.android.launcher3.views.BaseDragLayer.LayoutParams; import java.util.Collections; import java.util.List; @@ -165,6 +168,16 @@ public final class TaskbarAllAppsController { mSlideInView = (TaskbarAllAppsSlideInView) mOverlayContext.getLayoutInflater().inflate( R.layout.taskbar_all_apps_sheet, mOverlayContext.getDragLayer(), false); + + if (!mOverlayContext.isPrimaryDisplay() + && DesktopExperienceFlags.ENABLE_TASKBAR_CONNECTED_DISPLAYS.isTrue()) { + LayoutParams lp = (LayoutParams) mSlideInView.getLayoutParams(); + lp.height = mOverlayContext.getResources().getDimensionPixelSize( + R.dimen.all_apps_secondary_display_height); + lp.gravity = Gravity.BOTTOM; + mSlideInView.setLayoutParams(lp); + } + // Ensures All Apps gets touch events in case it is not the top floating view. Floating // views above it may not be able to intercept the touch, so All Apps should try to. mOverlayContext.getDragLayer().addTouchController(mSlideInView); diff --git a/res/values/dimens.xml b/res/values/dimens.xml index eaf19ca6c7..a7692e0715 100644 --- a/res/values/dimens.xml +++ b/res/values/dimens.xml @@ -156,6 +156,8 @@ 8dp + 900dp + 56dp 16dp