Updating landscape layout for launcher/quickstep
> Hotseat is tied to navbar (on left in seascape)
> Search box shows up in Overview (clicking it would crash for now)
> All-apps is no longer fullscreen in landscape
> Recents cards are appropriately scaled down
> Hotseat is visible in Overview
Bug: 70179916
Change-Id: I53149eaeac9557e8a01021b7e2d139f3d6ceef37
diff --git a/src/com/android/launcher3/LauncherState.java b/src/com/android/launcher3/LauncherState.java
index a1f5879..4f65d19 100644
--- a/src/com/android/launcher3/LauncherState.java
+++ b/src/com/android/launcher3/LauncherState.java
@@ -55,7 +55,7 @@
private static final LauncherState[] sAllStates = new LauncherState[4];
public static final LauncherState NORMAL = new LauncherState(0, ContainerType.WORKSPACE,
- 0, 1f, FLAG_DISABLE_RESTORE | FLAG_WORKSPACE_ICONS_CAN_BE_DRAGGED);
+ 0, FLAG_DISABLE_RESTORE | FLAG_WORKSPACE_ICONS_CAN_BE_DRAGGED);
public static final LauncherState ALL_APPS = new AllAppsState(1);
@@ -95,13 +95,6 @@
public final int transitionDuration;
/**
- * Fraction shift in the vertical translation UI and related properties
- *
- * @see com.android.launcher3.allapps.AllAppsTransitionController
- */
- public final float verticalProgress;
-
- /**
* True if the state allows workspace icons to be dragged.
*/
public final boolean workspaceIconsCanBeDragged;
@@ -112,8 +105,7 @@
*/
public final boolean disablePageClipping;
- public LauncherState(int id, int containerType, int transitionDuration, float verticalProgress,
- int flags) {
+ public LauncherState(int id, int containerType, int transitionDuration, int flags) {
this.containerType = containerType;
this.transitionDuration = transitionDuration;
@@ -126,8 +118,6 @@
this.workspaceIconsCanBeDragged = (flags & FLAG_WORKSPACE_ICONS_CAN_BE_DRAGGED) != 0;
this.disablePageClipping = (flags & FLAG_DISABLE_PAGE_CLIPPING) != 0;
- this.verticalProgress = verticalProgress;
-
this.ordinal = id;
sAllStates[id] = this;
}
@@ -154,6 +144,15 @@
return launcher.getWorkspace();
}
+ /**
+ * Fraction shift in the vertical translation UI and related properties
+ *
+ * @see com.android.launcher3.allapps.AllAppsTransitionController
+ */
+ public float getVerticalProgress(Launcher launcher) {
+ return 1f;
+ }
+
public String getDescription(Launcher launcher) {
return launcher.getWorkspace().getCurrentPageDescription();
}
@@ -162,7 +161,7 @@
if (this != NORMAL || !launcher.getDeviceProfile().shouldFadeAdjacentWorkspaceScreens()) {
return DEFAULT_ALPHA_PROVIDER;
}
- final int centerPage = launcher.getWorkspace().getPageNearestToCenterOfScreen();
+ final int centerPage = launcher.getWorkspace().getNextPage();
return new PageAlphaProvider(ACCEL_2) {
@Override
public float getPageAlpha(int pageIndex) {