去掉抽屉,去掉取消按钮

This commit is contained in:
2020-11-16 16:56:51 +08:00
parent 888ba814ea
commit 5ef06d1b3f
12 changed files with 170 additions and 62 deletions

View File

@@ -26,24 +26,27 @@ public class AllAppsSwipeController extends AbstractStateChangeTouchController {
@Override
protected boolean canInterceptTouch(MotionEvent ev) {
if (ev.getAction() == MotionEvent.ACTION_DOWN) {
mTouchDownEvent = ev;
}
if (mCurrentAnimation != null) {
// If we are already animating from a previous state, we can intercept.
return true;
}
if (AbstractFloatingView.getTopOpenView(mLauncher) != null) {
return false;
}
if (!mLauncher.isInState(NORMAL) && !mLauncher.isInState(ALL_APPS)) {
// Don't listen for the swipe gesture if we are already in some other state.
return false;
}
if (mLauncher.isInState(ALL_APPS) && !mLauncher.getAppsView().shouldContainerScroll(ev)) {
return false;
}
return true;
return false;
// if (ev.getAction() == MotionEvent.ACTION_DOWN) {
// mTouchDownEvent = ev;
// }
// if (mCurrentAnimation != null) {
// // If we are already animating from a previous state, we can intercept.
// return true;
// }
// if (AbstractFloatingView.getTopOpenView(mLauncher) != null) {
// return false;
// }
// if (!mLauncher.isInState(NORMAL) && !mLauncher.isInState(ALL_APPS)) {
// // Don't listen for the swipe gesture if we are already in some other state.
// return false;
// }
// if (mLauncher.isInState(ALL_APPS) && !mLauncher.getAppsView().shouldContainerScroll(ev)) {
// return false;
// }
// return true;
}
@Override