It would better move logic of transferTouchFocusToImeWindow
from WindowManagerService to InputMethodManagerService.
Bug: 149574510
Test: atest CtsAutoFillServiceTestCases
Test: atest CtsInputMethodTestCases
Change-Id: I268b09781e5eb7c77c4912efdc8fd5d6936ada27
* Use the original authentication instead
* Also support sending intent from augmented autofill, with the
limitation of not supporting sending back the FillResponse or
Dataset from the activity result
Test: manual
Test: atest android.autofillservice.cts.inline
Test: atest android.autofillservice.cts.FillResponseTest
Test: atest android.autofillservice.cts.augmented
Test: atest android.autofillservice.cts.LoginActivityTest
Bug: 150499490
Change-Id: I81031ff456adb4c07f530188dda80e97cc84b707
* by using the same lock from the autofill Session
Test: manual
Test: atest android.autofillservice.cts.inline
Bug: 151580124
Change-Id: Ia34b1d0ea85c24eddf1cf1b89d07c331bb411023
This reverts commit 949ec8ad6baf5516cbfd27b7e24d0e563c1f42a9.
Reason for revert: will check in the original patch with a fix
Test: manual
Test: atest android.autofillservice.cts.inline
Bug: 151580124
Bug: 150757314
Change-Id: I37d05eb627595c25018dd82e50db3a9b054c90a5
This reverts commit 69471c8f155327fe55b4bb7f9db9ac2be454ab17.
Reason for revert:
Caused a deadlock between AutofillManagerService#mLock and
InlineSuggestionsRequestCallbackImpl#mLock.
Bug: 150757314
Fix: 151580124
Test: presubmit
Change-Id: Ic021facea34cbc34ad5e113790e739ab7f472c1f
* Before this change, we were putting the action intent in the Slice,
but we realize that's not the best place as slice is only meant for
data representation, and intent does not fall into that
* This patch includes the code to actually fire the pending intent when
action suggestion is clicked. However, it'll only work if the fill
service have the SYSTEM_ALERT_WINDOW permission for the intent to
be fired when it is in the background. We will move it to be fired
from the client foreground app in a separate patch
Test: manual verification
Test: atest android.autofillservice.cts.inline
Bug: 150499490
Change-Id: I411a7ee05e783f7de94a54064c44a6126afe0b12
* Don't send multiple request when focused view doesn't change
* The difference is *when to return*. In the old code, we are returning
only when all four conditions are met, otherwise we will go to the
next lines requestNewFillResponseOnViewEnteredIfNecessaryLocked()
which will indeed trigger a new augmented autofill request. In the
new code, we will return if the three conditions are met, or if the
other three conditions are met...
Test: manual verification
Test: atest android.autofillservice.cts.inline
Test: atest android.autofillservice.cts.augmented
Bug: 145949573
Change-Id: I9ff3873e3aec8c1366d4aa16c9ef7662cfde45e2
* autofill will cache the inline suggestions response until it receives
a start input view event from IME
* the data flow from IMS point of view is:
IMS#startViews and IMS#doStartInput (before calling onStartInputView)
->
[async] InlineSuggestionsRequestCallback#onInputMethodStartInputView()
--- process boundary ---
->
IMMS.InlineSuggestionsRequestCallbackDecorator
#onInputMethodStartInputView()
->
InlineSuggestionSession.InlineSuggestionsRequestCallbackImpl
#onInputMethodStartInputView()
* similar data flow for IMS#finishViews()
* this CL should not block IME's UI thread because it's only issuing a
new async IPC from IMS start/finish input view call that's running on
the UI thread.
* there should not be performance impact on IMEs if autofill inline
integration is not active
Test: manual verification, atest EditorInfoTest
Test: atest android.autofillservice.cts.inline, with two failing cases:
InlineAugmentedLoginActivityTest#testAugmentedAutoFill_twoDatasetThenFilledSecond
and InlineAugmentedLoginActivityTest#testAugmentedAutoFill_oneDatasetThenFilled
due to the test itself being broken, I'll fix the test in a separate patch
Bug: 149522488
Bug: 149442582
Change-Id: I2faa3577b9f95a122f26a6d7fa7822a769a51e34
Add null checks to ensure RemoteInlineSuggestionRenderService is not
being called if service component cannot be found.
Fixes: 150315090
Fixes: 150318779
Fixes: 150319014
Fixes: 150039791
Fixes: 150304313
Test: atest CtsAutoFillServiceTestCases --instant
Test: atest CtsInputMethodServiceHostTestCases --instant
Change-Id: Ie8c84b12a0dc8e7415d94e4edb919de27827b799
The InlineContentView uses the SurfacePackage instead of the SurfaceControl
for accessibility and UiAutomation supporting.
Bug: 149194105
Test: manual
Change-Id: Ib10f37a58dde7dc09d0ea16d1a121088dab4738e
* Pipe the augmented autofill's inline actions through to the
InlineSuggestionsResponse
* Do not send the inline action if the number of inline suggestions is
zero
* Refactor autofill inline suggstion session so that all the calls to
the IME has happens within the class
* Send an empty response to IME to hide the inline suggestion UI when
view exits and the previous response wasn't empty
Test: manual verification, atest InlineLoginActivityTest
Bug: 149522488
Bug: 150312201
Change-Id: I7a0dbf44e9fad6e7da857448c0f2b186e1681d17
Autofill providers are allowed to pass back datasets that do not always
contain data for all views present. Inline response will ignore datasets
not relevant to currently focused AutofillId or those without an
InlinePresentation.
Fixes: 150312101
Test: atest InlineLoginActivityTest
Change-Id: Ie4d48eec571d4ccbfcbff8aa3ad4a75f7716072c
* add isPinned() to InlineSuggestionInfo so IME can choose to pin the suggestion
* allow augmented autofill service to set inline actions in the response
* non-api change: pull the autofill hints from the Slice in the InlinePresentation
Test: m -j; atest InlinePresentationTest, atest CtsInputMethodTestCases:InlineSuggestionInfoTest CtsInputMethodTestCases:InlineSuggestionTest
Bug: 137800469
Change-Id: I63b6b843ef056df18c317299e617b8fe21907374
The inline authentication change ag/10235929 changes the parameter of
createInlineSuggestion from fieldIndex to datasetIndex. However, the
passed parameter forget to change to datasetIndex. It is possible to
trigger IndexOutOfBoundsException when we have multiple fields but
only one dataset.
Bug: 149891961
Test: atest android.autofillservice.cts.inline.InlineAuthenticationTest
Test: Manual test by local sample
Change-Id: Iec074b14f2aa3fdb7de918ad684192921b9c5d65
Make obtaining a visual service from non-visual Context instance
report a strict mode violation and print the stacktrace.
Make calling getDisplay() throw an exception if called on an instance
that is not associated with a display. For existing usages introduce
a new internal method that does not perform the verification until
the usages are properly fixed.
Bug: 128338354
Test: StrictModeTest#testIncorrectContextUse_GetSystemService
Test: StrictModeTest#testIncorrectContextUse_GetDisplay
Change-Id: Id25d590eca6e10066e55d7ed6436d3bc9e433beb
* The bundle will be generated/consumed by the support library.
* More API documentation and example usage will be added later once we have the support library impl ready.
* The old style resource name approach doesn't work due to the potential mismatch in the support library version across the host IME and the platform renderer service, and the non-static nature of the public attribute int id in the support lib.
* The Bundle added to the onCreateInlineSuggestionsRequest() is intended for the platform/ExtServices to communicate the UI versions it supports.
* The Bundle added to the InlinePresentationSpec is intended for the IME to communicate the custom styles for the chosen UI versions.
Test: manual verification, and also atest CtsInputMethodTestCases:InlineSuggestionInfoTest CtsInputMethodTestCases:InlineSuggestionTest CtsInputMethodTestCases:InlineSuggestionsRequestTest CtsInputMethodTestCases:InlineSuggestionsResponseTest
Bug: 146454892
Change-Id: Id7fea32a7550fb924fec811b376790474a7b92eb
Timeout for waiting the event history
Fixes: 149720333
Test: atest CtsAutoFillServiceTestCases:FillEventHistoryTest
Change-Id: I9056508c12f7a4d946fbdb7cde053e5ca81104cf
Added a render service in ExtServices to connect to the renderer in
androidx.autofill for inline suggestion slices.
Cleaned up old UI rendering code that lived in system_server.
Bug: 146453086
Test: atest ExtServicesUnitTests
Change-Id: I25a7ea438afe524683671c850625ae80dacccfaa
Does not include filtering for Augmented Autofill.
The InlineSuggestionsResponse callback is called on every input change
as a mitigation for an IME attempting to glean potentially sensitive
content of the suggestions.
CLs will follow for disabling filtering in certain situations (to
prevent the Keyboard from gleaning the suggestions) and for caching the
inflates).
Test: manual
Test: atest CtsAutoFillServiceTestCases CtsInputMethodTestCases
Bug: 146452916
Change-Id: I396c2cb279f1eb552bbae8c3509cb29c95e86609