Remove workspace card

Swiping up for recents scales down workspace and hides it, similar to the transition
to all apps. Simultaneously, recents slides in from the side.

Also removed the setting for swiping to the first task, as it is required now.

Change-Id: Id0845db6650a37917a4faa9c8a434a2270913904
This commit is contained in:
Tony
2018-03-09 22:01:47 +00:00
parent 5cd8ab938c
commit 404e625516
10 changed files with 58 additions and 136 deletions

View File

@@ -16,7 +16,7 @@
package com.android.launcher3.uioverrides;
import static com.android.launcher3.LauncherAnimUtils.OVERVIEW_TRANSITION_MS;
import static com.android.launcher3.anim.Interpolators.ACCEL_2;
import static com.android.launcher3.anim.Interpolators.DEACCEL_2;
import static com.android.launcher3.states.RotationHelper.REQUEST_ROTATE;
import android.graphics.Rect;
@@ -34,7 +34,7 @@ import com.android.quickstep.RecentsView;
public class OverviewState extends LauncherState {
private static final int STATE_FLAGS = FLAG_SHOW_SCRIM | FLAG_WORKSPACE_ICONS_CAN_BE_DRAGGED
| FLAG_DISABLE_RESTORE | FLAG_PAGE_BACKGROUNDS | FLAG_OVERVIEW_UI;
| FLAG_DISABLE_RESTORE | FLAG_OVERVIEW_UI;
public OverviewState(int id) {
this(id, STATE_FLAGS);
@@ -79,11 +79,10 @@ public class OverviewState extends LauncherState {
}
public PageAlphaProvider getWorkspacePageAlphaProvider(Launcher launcher) {
final int centerPage = launcher.getWorkspace().getNextPage();
return new PageAlphaProvider(ACCEL_2) {
return new PageAlphaProvider(DEACCEL_2) {
@Override
public float getPageAlpha(int pageIndex) {
return pageIndex != centerPage ? 0 : 1f;
return 0;
}
};
}