Loading services/autofill/java/com/android/server/autofill/AutofillInlineSessionController.java +16 −0 Original line number Diff line number Diff line Loading @@ -126,6 +126,22 @@ final class AutofillInlineSessionController { return hideInlineSuggestionsUiLocked(autofillId); } /** * Clear the locally cached inline fill UI, but don't clear the suggestion in the IME. * * <p>This is called to invalid the locally cached inline suggestions so we don't resend them * to the IME, while assuming that the IME will clean up suggestion on their own when the input * connection is finished. We don't send an empty response to IME so that it doesn't cause UI * flicker on the IME side if it arrives before the input view is finished on the IME. */ @GuardedBy("mLock") void resetInlineFillUiLocked() { mInlineFillUi = null; if (mSession != null) { mSession.resetInlineFillUiLocked(); } } /** * Updates the inline fill UI with the filter text. It'll send updated inline suggestions to * the IME. Loading services/autofill/java/com/android/server/autofill/AutofillInlineSuggestionsRequestSession.java +10 −0 Original line number Diff line number Diff line Loading @@ -190,6 +190,16 @@ final class AutofillInlineSuggestionsRequestSession { new InlineSuggestionsRequestCallbackImpl(this)); } /** * Clear the locally cached inline fill UI, but don't clear the suggestion in IME. * * See also {@link AutofillInlineSessionController#resetInlineFillUiLocked()} */ @GuardedBy("mLock") void resetInlineFillUiLocked() { mInlineFillUi = null; } /** * Optionally sends inline response to the IME, depending on the current state. */ Loading services/autofill/java/com/android/server/autofill/Session.java +3 −0 Original line number Diff line number Diff line Loading @@ -2581,6 +2581,9 @@ final class Session implements RemoteFillService.FillServiceCallbacks, ViewState if (sVerbose) Slog.v(TAG, "Exiting view " + id); mUi.hideFillUi(this); hideAugmentedAutofillLocked(viewState); // We don't send an empty response to IME so that it doesn't cause UI flicker // on the IME side if it arrives before the input view is finished on the IME. mInlineSessionController.resetInlineFillUiLocked(); mCurrentViewId = null; } break; Loading Loading
services/autofill/java/com/android/server/autofill/AutofillInlineSessionController.java +16 −0 Original line number Diff line number Diff line Loading @@ -126,6 +126,22 @@ final class AutofillInlineSessionController { return hideInlineSuggestionsUiLocked(autofillId); } /** * Clear the locally cached inline fill UI, but don't clear the suggestion in the IME. * * <p>This is called to invalid the locally cached inline suggestions so we don't resend them * to the IME, while assuming that the IME will clean up suggestion on their own when the input * connection is finished. We don't send an empty response to IME so that it doesn't cause UI * flicker on the IME side if it arrives before the input view is finished on the IME. */ @GuardedBy("mLock") void resetInlineFillUiLocked() { mInlineFillUi = null; if (mSession != null) { mSession.resetInlineFillUiLocked(); } } /** * Updates the inline fill UI with the filter text. It'll send updated inline suggestions to * the IME. Loading
services/autofill/java/com/android/server/autofill/AutofillInlineSuggestionsRequestSession.java +10 −0 Original line number Diff line number Diff line Loading @@ -190,6 +190,16 @@ final class AutofillInlineSuggestionsRequestSession { new InlineSuggestionsRequestCallbackImpl(this)); } /** * Clear the locally cached inline fill UI, but don't clear the suggestion in IME. * * See also {@link AutofillInlineSessionController#resetInlineFillUiLocked()} */ @GuardedBy("mLock") void resetInlineFillUiLocked() { mInlineFillUi = null; } /** * Optionally sends inline response to the IME, depending on the current state. */ Loading
services/autofill/java/com/android/server/autofill/Session.java +3 −0 Original line number Diff line number Diff line Loading @@ -2581,6 +2581,9 @@ final class Session implements RemoteFillService.FillServiceCallbacks, ViewState if (sVerbose) Slog.v(TAG, "Exiting view " + id); mUi.hideFillUi(this); hideAugmentedAutofillLocked(viewState); // We don't send an empty response to IME so that it doesn't cause UI flicker // on the IME side if it arrives before the input view is finished on the IME. mInlineSessionController.resetInlineFillUiLocked(); mCurrentViewId = null; } break; Loading