Loading quickstep/src/com/android/launcher3/WidgetPickerActivity.java +0 −6 Original line number Diff line number Diff line Loading @@ -20,7 +20,6 @@ import static android.content.ClipDescription.MIMETYPE_TEXT_INTENT; import static android.view.WindowInsets.Type.navigationBars; import static android.view.WindowInsets.Type.statusBars; import static com.android.launcher3.Flags.enablePredictiveBackGesture; import static com.android.launcher3.util.Executors.MAIN_EXECUTOR; import static com.android.launcher3.util.Executors.MODEL_EXECUTOR; Loading Loading @@ -170,11 +169,6 @@ public class WidgetPickerActivity extends BaseActivity { @Override protected void registerBackDispatcher() { if (!enablePredictiveBackGesture()) { super.registerBackDispatcher(); return; } getOnBackInvokedDispatcher().registerOnBackInvokedCallback( OnBackInvokedDispatcher.PRIORITY_DEFAULT, new BackAnimationCallback()); Loading quickstep/src/com/android/launcher3/taskbar/allapps/TaskbarAllAppsSlideInView.java +11 −16 Original line number Diff line number Diff line Loading @@ -16,7 +16,6 @@ package com.android.launcher3.taskbar.allapps; import static com.android.app.animation.Interpolators.EMPHASIZED; import static com.android.launcher3.Flags.enablePredictiveBackGesture; import static com.android.launcher3.touch.AllAppsSwipeController.ALL_APPS_FADE_MANUAL; import static com.android.launcher3.touch.AllAppsSwipeController.SCRIM_FADE_MANUAL; Loading Loading @@ -193,7 +192,6 @@ public class TaskbarAllAppsSlideInView extends AbstractSlideInView<TaskbarOverla protected void onAttachedToWindow() { super.onAttachedToWindow(); mActivityContext.addOnDeviceProfileChangeListener(this); if (enablePredictiveBackGesture()) { mAppsView.getAppsRecyclerViewContainer().setOutlineProvider(mViewOutlineProvider); mAppsView.getAppsRecyclerViewContainer().setClipToOutline(true); OnBackInvokedDispatcher dispatcher = findOnBackInvokedDispatcher(); Loading @@ -202,13 +200,11 @@ public class TaskbarAllAppsSlideInView extends AbstractSlideInView<TaskbarOverla OnBackInvokedDispatcher.PRIORITY_DEFAULT, this); } } } @Override protected void onDetachedFromWindow() { super.onDetachedFromWindow(); mActivityContext.removeOnDeviceProfileChangeListener(this); if (enablePredictiveBackGesture()) { mAppsView.getAppsRecyclerViewContainer().setOutlineProvider(null); mAppsView.getAppsRecyclerViewContainer().setClipToOutline(false); OnBackInvokedDispatcher dispatcher = findOnBackInvokedDispatcher(); Loading @@ -216,7 +212,6 @@ public class TaskbarAllAppsSlideInView extends AbstractSlideInView<TaskbarOverla dispatcher.unregisterOnBackInvokedCallback(this); } } } @Override protected void dispatchDraw(Canvas canvas) { Loading quickstep/src/com/android/launcher3/uioverrides/QuickstepLauncher.java +2 −10 Original line number Diff line number Diff line Loading @@ -22,7 +22,6 @@ import static android.view.accessibility.AccessibilityEvent.TYPE_VIEW_FOCUSED; import static com.android.app.animation.Interpolators.EMPHASIZED; import static com.android.internal.jank.Cuj.CUJ_LAUNCHER_LAUNCH_APP_PAIR_FROM_WORKSPACE; import static com.android.launcher3.Flags.enablePredictiveBackGesture; import static com.android.launcher3.Flags.enableUnfoldStateAnimation; import static com.android.launcher3.LauncherConstants.SavedInstanceKeys.PENDING_SPLIT_SELECT_INFO; import static com.android.launcher3.LauncherConstants.SavedInstanceKeys.RUNTIME_STATE; Loading Loading @@ -696,9 +695,7 @@ public class QuickstepLauncher extends Launcher implements RecentsViewContainer, // Back dispatcher is registered in {@link BaseActivity#onCreate}. For predictive back to // work, we must opt-in BEFORE registering back dispatcher. So we need to call // setEnableOnBackInvokedCallback() before super.onCreate() if (Utilities.ATLEAST_U && enablePredictiveBackGesture()) { getApplicationInfo().setEnableOnBackInvokedCallback(true); } super.onCreate(savedInstanceState); if (savedInstanceState != null) { mPendingSplitSelectInfo = ObjectWrapper.unwrap( Loading Loading @@ -910,8 +907,7 @@ public class QuickstepLauncher extends Launcher implements RecentsViewContainer, // event won't go through ViewRootImpl#InputStage#onProcess. // So when receive back key, try to do the same check thing in // ViewRootImpl#NativePreImeInputStage#onProcess if (!Utilities.ATLEAST_U || !enablePredictiveBackGesture() || event.getKeyCode() != KeyEvent.KEYCODE_BACK if (event.getKeyCode() != KeyEvent.KEYCODE_BACK || event.getAction() != KeyEvent.ACTION_UP || event.isCanceled()) { return false; } Loading @@ -922,10 +918,6 @@ public class QuickstepLauncher extends Launcher implements RecentsViewContainer, @Override protected void registerBackDispatcher() { if (!enablePredictiveBackGesture()) { super.registerBackDispatcher(); return; } getOnBackInvokedDispatcher().registerOnBackInvokedCallback( OnBackInvokedDispatcher.PRIORITY_DEFAULT, new OnBackAnimationCallback() { Loading Loading
quickstep/src/com/android/launcher3/WidgetPickerActivity.java +0 −6 Original line number Diff line number Diff line Loading @@ -20,7 +20,6 @@ import static android.content.ClipDescription.MIMETYPE_TEXT_INTENT; import static android.view.WindowInsets.Type.navigationBars; import static android.view.WindowInsets.Type.statusBars; import static com.android.launcher3.Flags.enablePredictiveBackGesture; import static com.android.launcher3.util.Executors.MAIN_EXECUTOR; import static com.android.launcher3.util.Executors.MODEL_EXECUTOR; Loading Loading @@ -170,11 +169,6 @@ public class WidgetPickerActivity extends BaseActivity { @Override protected void registerBackDispatcher() { if (!enablePredictiveBackGesture()) { super.registerBackDispatcher(); return; } getOnBackInvokedDispatcher().registerOnBackInvokedCallback( OnBackInvokedDispatcher.PRIORITY_DEFAULT, new BackAnimationCallback()); Loading
quickstep/src/com/android/launcher3/taskbar/allapps/TaskbarAllAppsSlideInView.java +11 −16 Original line number Diff line number Diff line Loading @@ -16,7 +16,6 @@ package com.android.launcher3.taskbar.allapps; import static com.android.app.animation.Interpolators.EMPHASIZED; import static com.android.launcher3.Flags.enablePredictiveBackGesture; import static com.android.launcher3.touch.AllAppsSwipeController.ALL_APPS_FADE_MANUAL; import static com.android.launcher3.touch.AllAppsSwipeController.SCRIM_FADE_MANUAL; Loading Loading @@ -193,7 +192,6 @@ public class TaskbarAllAppsSlideInView extends AbstractSlideInView<TaskbarOverla protected void onAttachedToWindow() { super.onAttachedToWindow(); mActivityContext.addOnDeviceProfileChangeListener(this); if (enablePredictiveBackGesture()) { mAppsView.getAppsRecyclerViewContainer().setOutlineProvider(mViewOutlineProvider); mAppsView.getAppsRecyclerViewContainer().setClipToOutline(true); OnBackInvokedDispatcher dispatcher = findOnBackInvokedDispatcher(); Loading @@ -202,13 +200,11 @@ public class TaskbarAllAppsSlideInView extends AbstractSlideInView<TaskbarOverla OnBackInvokedDispatcher.PRIORITY_DEFAULT, this); } } } @Override protected void onDetachedFromWindow() { super.onDetachedFromWindow(); mActivityContext.removeOnDeviceProfileChangeListener(this); if (enablePredictiveBackGesture()) { mAppsView.getAppsRecyclerViewContainer().setOutlineProvider(null); mAppsView.getAppsRecyclerViewContainer().setClipToOutline(false); OnBackInvokedDispatcher dispatcher = findOnBackInvokedDispatcher(); Loading @@ -216,7 +212,6 @@ public class TaskbarAllAppsSlideInView extends AbstractSlideInView<TaskbarOverla dispatcher.unregisterOnBackInvokedCallback(this); } } } @Override protected void dispatchDraw(Canvas canvas) { Loading
quickstep/src/com/android/launcher3/uioverrides/QuickstepLauncher.java +2 −10 Original line number Diff line number Diff line Loading @@ -22,7 +22,6 @@ import static android.view.accessibility.AccessibilityEvent.TYPE_VIEW_FOCUSED; import static com.android.app.animation.Interpolators.EMPHASIZED; import static com.android.internal.jank.Cuj.CUJ_LAUNCHER_LAUNCH_APP_PAIR_FROM_WORKSPACE; import static com.android.launcher3.Flags.enablePredictiveBackGesture; import static com.android.launcher3.Flags.enableUnfoldStateAnimation; import static com.android.launcher3.LauncherConstants.SavedInstanceKeys.PENDING_SPLIT_SELECT_INFO; import static com.android.launcher3.LauncherConstants.SavedInstanceKeys.RUNTIME_STATE; Loading Loading @@ -696,9 +695,7 @@ public class QuickstepLauncher extends Launcher implements RecentsViewContainer, // Back dispatcher is registered in {@link BaseActivity#onCreate}. For predictive back to // work, we must opt-in BEFORE registering back dispatcher. So we need to call // setEnableOnBackInvokedCallback() before super.onCreate() if (Utilities.ATLEAST_U && enablePredictiveBackGesture()) { getApplicationInfo().setEnableOnBackInvokedCallback(true); } super.onCreate(savedInstanceState); if (savedInstanceState != null) { mPendingSplitSelectInfo = ObjectWrapper.unwrap( Loading Loading @@ -910,8 +907,7 @@ public class QuickstepLauncher extends Launcher implements RecentsViewContainer, // event won't go through ViewRootImpl#InputStage#onProcess. // So when receive back key, try to do the same check thing in // ViewRootImpl#NativePreImeInputStage#onProcess if (!Utilities.ATLEAST_U || !enablePredictiveBackGesture() || event.getKeyCode() != KeyEvent.KEYCODE_BACK if (event.getKeyCode() != KeyEvent.KEYCODE_BACK || event.getAction() != KeyEvent.ACTION_UP || event.isCanceled()) { return false; } Loading @@ -922,10 +918,6 @@ public class QuickstepLauncher extends Launcher implements RecentsViewContainer, @Override protected void registerBackDispatcher() { if (!enablePredictiveBackGesture()) { super.registerBackDispatcher(); return; } getOnBackInvokedDispatcher().registerOnBackInvokedCallback( OnBackInvokedDispatcher.PRIORITY_DEFAULT, new OnBackAnimationCallback() { Loading