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

Commit b0404606 authored by Ming-Shin Lu's avatar Ming-Shin Lu Committed by Automerger Merge Worker
Browse files

Merge "Revert hide logic in ImeInsetsSourceConsumer#setControl" into sc-v2-dev am: cf9560a4

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16334306

Change-Id: I9b0dd9d77181794e93e3d5eb4d8e9c606b27d7ca
parents 669edf20 cf9560a4
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -124,7 +124,12 @@ public final class ImeInsetsSourceConsumer extends InsetsSourceConsumer {
    public void setControl(@Nullable InsetsSourceControl control, int[] showTypes,
            int[] hideTypes) {
        super.setControl(control, showTypes, hideTypes);
        if (control == null && !isRequestedVisibleAwaitingControl()) {
        // TODO(b/204524304): clean-up how to deal with the timing issues of hiding IME:
        //  1) Already requested show IME, in the meantime of WM callback the control but got null
        //  control when relayout comes first
        //  2) Make sure no regression on some implicit request IME visibility calls (e.g.
        //  toggleSoftInput)
        if (control == null && !mIsRequestedVisibleAwaitingControl) {
            hide();
            removeSurface();
        }