OSDN Git Service

Inject session id on all AutofillIds kept in the service.
authorFelipe Leme <felipeal@google.com>
Wed, 1 May 2019 01:12:50 +0000 (18:12 -0700)
committerFelipe Leme <felipeal@google.com>
Thu, 2 May 2019 01:10:00 +0000 (18:10 -0700)
commit785777bb05812e0a5359e55fa85224bd271735c3
tree3ebc370fff593ebddc1c2fc5c7c207ec0330894e
parent7b307ea7b2db82e4881ae66bb3fc805185da936e
Inject session id on all AutofillIds kept in the service.

Android Q introduce the FLAG_DELAY_SAVE, which allows the autofill service to delay the SAVE UI by
keeping the session open. But this approach introduces a new problem, as fields from different
activities could have the same AutofillId.

Test: atest MultiScreenLoginTest#testSaveBothFieldsCustomDescription_sameIds
Test: atest AutofillIdTest
Test: atest CtsAutoFillServiceTestCases # sanity check

Fixes: 113593220

Change-Id: Ibd187f5c58c150f820972fcab6d88217294ffe2d
core/java/android/app/assist/AssistStructure.java
core/java/android/view/autofill/AutofillId.java
core/java/android/view/autofill/AutofillManager.java
core/tests/coretests/src/android/view/autofill/AutofillIdTest.java
services/autofill/java/com/android/server/autofill/Helper.java
services/autofill/java/com/android/server/autofill/Session.java
services/autofill/java/com/android/server/autofill/ui/SaveUi.java