Updating to use deferred cancel api
- Also updating the sysui flag to home's flags when passing some threshold - Also ensure we don't allow swipe up when QS is open Bug: 137196872 Bug: 135969043 Change-Id: I476eee7f02ae86aa795fceabb304bcaa7416ef9c
This commit is contained in:
+2
-2
@@ -188,9 +188,9 @@ public class RecentsAnimationWrapper {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setCancelWithDeferredScreenshot(boolean deferredWithScreenshot) {
|
public void setDeferCancelUntilNextTransition(boolean defer, boolean screenshot) {
|
||||||
if (targetSet != null) {
|
if (targetSet != null) {
|
||||||
targetSet.controller.setCancelWithDeferredScreenshot(deferredWithScreenshot);
|
targetSet.controller.setDeferCancelUntilNextTransition(defer, screenshot);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -31,6 +31,7 @@ import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_H
|
|||||||
import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_NAV_BAR_HIDDEN;
|
import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_NAV_BAR_HIDDEN;
|
||||||
import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_NOTIFICATION_PANEL_EXPANDED;
|
import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_NOTIFICATION_PANEL_EXPANDED;
|
||||||
import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_OVERVIEW_DISABLED;
|
import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_OVERVIEW_DISABLED;
|
||||||
|
import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_QUICK_SETTINGS_EXPANDED;
|
||||||
import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_SCREEN_PINNING;
|
import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_SCREEN_PINNING;
|
||||||
import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_STATUS_BAR_KEYGUARD_SHOWING_OCCLUDED;
|
import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_STATUS_BAR_KEYGUARD_SHOWING_OCCLUDED;
|
||||||
import static com.android.systemui.shared.system.RemoteAnimationTargetCompat.ACTIVITY_TYPE_ASSISTANT;
|
import static com.android.systemui.shared.system.RemoteAnimationTargetCompat.ACTIVITY_TYPE_ASSISTANT;
|
||||||
@@ -569,6 +570,7 @@ public class TouchInteractionService extends Service implements
|
|||||||
private boolean validSystemUiFlags() {
|
private boolean validSystemUiFlags() {
|
||||||
return (mSystemUiStateFlags & SYSUI_STATE_NAV_BAR_HIDDEN) == 0
|
return (mSystemUiStateFlags & SYSUI_STATE_NAV_BAR_HIDDEN) == 0
|
||||||
&& (mSystemUiStateFlags & SYSUI_STATE_NOTIFICATION_PANEL_EXPANDED) == 0
|
&& (mSystemUiStateFlags & SYSUI_STATE_NOTIFICATION_PANEL_EXPANDED) == 0
|
||||||
|
&& (mSystemUiStateFlags & SYSUI_STATE_QUICK_SETTINGS_EXPANDED) == 0
|
||||||
&& ((mSystemUiStateFlags & SYSUI_STATE_HOME_DISABLED) == 0
|
&& ((mSystemUiStateFlags & SYSUI_STATE_HOME_DISABLED) == 0
|
||||||
|| (mSystemUiStateFlags & SYSUI_STATE_OVERVIEW_DISABLED) == 0);
|
|| (mSystemUiStateFlags & SYSUI_STATE_OVERVIEW_DISABLED) == 0);
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-1
@@ -1186,7 +1186,8 @@ public class WindowTransformSwipeHandler<T extends BaseDraggingActivity>
|
|||||||
private void setupLauncherUiAfterSwipeUpToRecentsAnimation() {
|
private void setupLauncherUiAfterSwipeUpToRecentsAnimation() {
|
||||||
endLauncherTransitionController();
|
endLauncherTransitionController();
|
||||||
mActivityControlHelper.onSwipeUpToRecentsComplete(mActivity);
|
mActivityControlHelper.onSwipeUpToRecentsComplete(mActivity);
|
||||||
mRecentsAnimationWrapper.setCancelWithDeferredScreenshot(true);
|
mRecentsAnimationWrapper.setDeferCancelUntilNextTransition(true /* defer */,
|
||||||
|
true /* screenshot */);
|
||||||
mRecentsView.onSwipeUpAnimationSuccess();
|
mRecentsView.onSwipeUpAnimationSuccess();
|
||||||
|
|
||||||
RecentsModel.INSTANCE.get(mContext).onOverviewShown(false, TAG);
|
RecentsModel.INSTANCE.get(mContext).onOverviewShown(false, TAG);
|
||||||
|
|||||||
+3
-1
@@ -50,6 +50,7 @@ import com.android.quickstep.fallback.FallbackRecentsView;
|
|||||||
import com.android.quickstep.util.ObjectWrapper;
|
import com.android.quickstep.util.ObjectWrapper;
|
||||||
import com.android.quickstep.util.RectFSpringAnim;
|
import com.android.quickstep.util.RectFSpringAnim;
|
||||||
import com.android.quickstep.util.SwipeAnimationTargetSet;
|
import com.android.quickstep.util.SwipeAnimationTargetSet;
|
||||||
|
import com.android.quickstep.views.RecentsView;
|
||||||
import com.android.quickstep.views.TaskView;
|
import com.android.quickstep.views.TaskView;
|
||||||
import com.android.systemui.shared.recents.model.ThumbnailData;
|
import com.android.systemui.shared.recents.model.ThumbnailData;
|
||||||
import com.android.systemui.shared.system.ActivityManagerWrapper;
|
import com.android.systemui.shared.system.ActivityManagerWrapper;
|
||||||
@@ -335,7 +336,8 @@ public class FallbackNoButtonInputConsumer extends
|
|||||||
|
|
||||||
ThumbnailData thumbnail =
|
ThumbnailData thumbnail =
|
||||||
mRecentsAnimationWrapper.targetSet.controller.screenshotTask(mRunningTaskId);
|
mRecentsAnimationWrapper.targetSet.controller.screenshotTask(mRunningTaskId);
|
||||||
mRecentsAnimationWrapper.setCancelWithDeferredScreenshot(true);
|
mRecentsAnimationWrapper.setDeferCancelUntilNextTransition(true /* defer */,
|
||||||
|
false /* screenshot */);
|
||||||
|
|
||||||
ActivityOptions options = ActivityOptions.makeCustomAnimation(mContext, 0, 0);
|
ActivityOptions options = ActivityOptions.makeCustomAnimation(mContext, 0, 0);
|
||||||
ActivityOptionsCompat.setFreezeRecentTasksList(options);
|
ActivityOptionsCompat.setFreezeRecentTasksList(options);
|
||||||
|
|||||||
Reference in New Issue
Block a user