From 7a593c23aef80dd992ead511967ba3cdadcafc61 Mon Sep 17 00:00:00 2001 From: Ming-Shin Lu Date: Fri, 15 Jul 2022 21:03:20 +0800 Subject: [PATCH] Remove hideCurrentInputMethod from RecentsAnimationController Since CL[1] migrate hide IME logic when quick switching split-screen task to InputMonitor. As a result, remove unused API since it would be no longer to expose hideCurrentInputMethod for launcher to handle gesture. [1]: Ibfcd48e623336c4690b71c4db0ce1ad8f5b26fc9 Bug: 166736352 Bug: 193990612 Test: manual test as steps 1) launch any apps with focusing an editor 2) from overview, select any app to enter split-screen mode 3) taping the editor to show the keyboard 4) swipe up to overview or quick switch app tasks 5) expect the keyboard will be hidden when starting the gesture. Change-Id: I299c3ac8531fa28c68c997e44fb168819e85d465 --- core/java/android/view/IRecentsAnimationController.aidl | 5 ----- .../shared/system/RecentsAnimationControllerCompat.java | 8 -------- .../systemui/shared/system/RemoteTransitionCompat.java | 4 ---- .../com/android/server/wm/RecentsAnimationController.java | 4 ---- 4 files changed, 21 deletions(-) diff --git a/core/java/android/view/IRecentsAnimationController.aidl b/core/java/android/view/IRecentsAnimationController.aidl index 61f524f517868..c4d307073d122 100644 --- a/core/java/android/view/IRecentsAnimationController.aidl +++ b/core/java/android/view/IRecentsAnimationController.aidl @@ -79,11 +79,6 @@ interface IRecentsAnimationController { @UnsupportedAppUsage void setAnimationTargetsBehindSystemBars(boolean behindSystemBars); - /** - * Hides the current input method if one is showing. - */ - void hideCurrentInputMethod(); - /** * Clean up the screenshot of previous task which was created during recents animation that * was cancelled by a stack order change. diff --git a/packages/SystemUI/shared/src/com/android/systemui/shared/system/RecentsAnimationControllerCompat.java b/packages/SystemUI/shared/src/com/android/systemui/shared/system/RecentsAnimationControllerCompat.java index 13f1db4a08316..0094820f0dad1 100644 --- a/packages/SystemUI/shared/src/com/android/systemui/shared/system/RecentsAnimationControllerCompat.java +++ b/packages/SystemUI/shared/src/com/android/systemui/shared/system/RecentsAnimationControllerCompat.java @@ -65,14 +65,6 @@ public class RecentsAnimationControllerCompat { } } - public void hideCurrentInputMethod() { - try { - mAnimationController.hideCurrentInputMethod(); - } catch (RemoteException e) { - Log.e(TAG, "Failed to set hide input method", e); - } - } - /** * Sets the final surface transaction on a Task. This is used by Launcher to notify the system * that animating Activity to PiP has completed and the associated task surface should be diff --git a/packages/SystemUI/shared/src/com/android/systemui/shared/system/RemoteTransitionCompat.java b/packages/SystemUI/shared/src/com/android/systemui/shared/system/RemoteTransitionCompat.java index ff2a7a1322887..609846e8c7292 100644 --- a/packages/SystemUI/shared/src/com/android/systemui/shared/system/RemoteTransitionCompat.java +++ b/packages/SystemUI/shared/src/com/android/systemui/shared/system/RemoteTransitionCompat.java @@ -369,10 +369,6 @@ public class RemoteTransitionCompat implements Parcelable { if (mWrapped != null) mWrapped.setAnimationTargetsBehindSystemBars(behindSystemBars); } - @Override public void hideCurrentInputMethod() { - mWrapped.hideCurrentInputMethod(); - } - @Override public void setFinishTaskTransaction(int taskId, PictureInPictureSurfaceTransaction finishTransaction, SurfaceControl overlay) { mPipTransaction = finishTransaction; diff --git a/services/core/java/com/android/server/wm/RecentsAnimationController.java b/services/core/java/com/android/server/wm/RecentsAnimationController.java index 08bf7bca93c44..53f1fe6abec5f 100644 --- a/services/core/java/com/android/server/wm/RecentsAnimationController.java +++ b/services/core/java/com/android/server/wm/RecentsAnimationController.java @@ -352,10 +352,6 @@ public class RecentsAnimationController implements DeathRecipient { } } - // TODO(b/166736352): Remove this method without the need to expose to launcher. - @Override - public void hideCurrentInputMethod() { } - @Override public void setDeferCancelUntilNextTransition(boolean defer, boolean screenshot) { synchronized (mService.mGlobalLock) {