Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2ed2600c authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Fix: Hiding IME via predictiveBack and focussing editText did not show it" into main

parents d157cbaa cf9a927c
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1083,7 +1083,7 @@ public class InsetsController implements WindowInsetsController, InsetsAnimation
        }
    }

    boolean isPredictiveBackImeHideAnimInProgress() {
    public boolean isPredictiveBackImeHideAnimInProgress() {
        return mIsPredictiveBackImeHideAnimInProgress;
    }

+8 −4
Original line number Diff line number Diff line
@@ -2400,10 +2400,14 @@ public final class InputMethodManager {
            if (Flags.refactorInsetsController()) {
                final var viewRootImpl = view.getViewRootImpl();
                // In case of a running show IME animation, it should not be requested visible,
                // otherwise the animation would jump and not be controlled by the user anymore
                if (viewRootImpl != null
                        && (viewRootImpl.getInsetsController().computeUserAnimatingTypes()
                                & WindowInsets.Type.ime()) == 0) {
                // otherwise the animation would jump and not be controlled by the user anymore.
                // If predictive back is in progress, and a editText is focussed, we should
                // show the IME.
                if (viewRootImpl != null && (
                        (viewRootImpl.getInsetsController().computeUserAnimatingTypes()
                                & WindowInsets.Type.ime()) == 0
                        || viewRootImpl.getInsetsController()
                                .isPredictiveBackImeHideAnimInProgress())) {
                    ImeTracker.forLogging().onProgress(statsToken,
                            ImeTracker.PHASE_CLIENT_NO_ONGOING_USER_ANIMATION);
                    if (resultReceiver != null) {