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

Commit c71f42e7 authored by Adam He's avatar Adam He
Browse files

Add call to send empty suggestions to IME on cancelling augmented

autofill.

Bug: 159472108
Test: atest InlineLoginActivityTest
Change-Id: Ie3bebffbee32dbfc11c931096a39641a4815293e
parent 59804dcc
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -2979,8 +2979,8 @@ final class Session implements RemoteFillService.FillServiceCallbacks, ViewState
                inlineSuggestionsRequest.get(), response, focusedId, filterText,
                /*uiCallback*/this, /*onErrorCallback*/ () -> {
                    synchronized (mLock) {
                        mInlineSessionController.hideInlineSuggestionsUiLocked(
                                focusedId);
                        mInlineSessionController.setInlineFillUiLocked(
                                InlineFillUi.emptyUi(focusedId));
                    }
                }, remoteRenderService);
        return mInlineSessionController.setInlineFillUiLocked(inlineFillUi);
@@ -3284,6 +3284,10 @@ final class Session implements RemoteFillService.FillServiceCallbacks, ViewState
                                /*onErrorCallback=*/ () -> {
                                    synchronized (mLock) {
                                        cancelAugmentedAutofillLocked();

                                        // Also cancel augmented in IME
                                        mInlineSessionController.setInlineFillUiLocked(
                                                InlineFillUi.emptyUi(mCurrentViewId));
                                    }
                                }, mService.getRemoteInlineSuggestionRenderServiceLocked());
                    }