History log of /frameworks/base/core/java/android/service/autofill/Dataset.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
36b86c28f88e4c7853a4255a0fd9b754cbb547c4 16-Apr-2018 Dake Gu <dake@google.com> Autofill: new UX for TV and support themes

1. Define default Themes for autofill window and save dialog.
(http://go/theme_autofill). Phone uses light themes, TV uses
dark themes.
2. Apply autofill theme to RemoteViews passed from autofill service.
So this can make sure the textColor of RemoteViews matches
the background of autofill theme uses.
Updated public javadoc that autofill service should not
hardcode color values.
3. A new TV ux that occupies half screen height (go/autofill-for-tv).
TV autofill now passes unhandled physical keyevent to app window
in the same way phone/tablet does.
4. Fixed ATV autofill window to be SYSTEM_DIALOG, so it wont be
clipped by app activity window (DialogLauncherActivityTest).

Bug: 71720680
Bug: 74072921
Test: CtsAutofillTest

Change-Id: Ib570227b0958b1800e8f0600b8aec36478568d74
/frameworks/base/core/java/android/service/autofill/Dataset.java
da9ea34c029df809e6b833a483408662e13ca9a1 22-Mar-2018 Felipe Leme <felipeal@google.com> Improved autofill logging and dumping.

Bug: 76027553
Test: adb shell dumpsys autofill

Change-Id: I19ef88c71334c62292ed982e43d7a7e89b35f10e
/frameworks/base/core/java/android/service/autofill/Dataset.java
09d58a4e3b374609601182c1dccb71a297bc97c8 30-Jan-2018 Felipe Leme <felipeal@google.com> Changed dataset methods that take a Pattern filter to accept null.

In this case, null means the field should not be filterable, which is useful
in the cases where it represents a non-authenticated value like a password.

Test: atest CtsAutoFillServiceTestCases:LoginActivityTest#filterTextDisabledUsingNullRegex
Test: atest CtsAutoFillServiceTestCases:LoginActivityTest

Bug: 71359055
Fixes: 72711778

Change-Id: Idc8248f6c95fdb50b934840689616e42ddd6378c
/frameworks/base/core/java/android/service/autofill/Dataset.java
bbf8549ad0bab9f73501956278b25c57a17eb5ab 22-Nov-2017 Felipe Leme <felipeal@google.com> Changed Dataset.setValue() methods to allow filtering with authentication.

The Dataset.setValue() methods were created before Datasets supported
RemoteViews as presentation. As such, the service always had to provide a
value for the dataset fields, and the value could not be used for filtering
(otherwise the user could "guess" what that authenticaed values were).

But once Dataset required RemoteViews for presentation, the field values were
not used anymore when the dataset required authentication (in fact, the
setValue() methods accepted null for the value), so now we can always use the
field values for filtering.

Test: atest CtsAutoFillServiceTestCases
Fixes: 69458842

Change-Id: Ia58af8bb946f31c3806c28570b2445870d7ccf0c
/frameworks/base/core/java/android/service/autofill/Dataset.java
601d22007488145f8651930d23aeb7a7a95cc591 17-Nov-2017 Felipe Leme <felipeal@google.com> Minor improvements on autofill javadocs and logging.

Test: m update-api
Bug: 69456547

Change-Id: I2cab6d7d6ecbe7c1842a5be37af923dd20355b73
/frameworks/base/core/java/android/service/autofill/Dataset.java
6f12e67e1724cc52d0f5a5ca0b201a612d2859d8 20-Oct-2017 Felipe Leme <felipeal@google.com> Minor improvements on Autofill:

- Don't print PII on Dataset.toString()
- Use proper method to get last response

Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases

Bug: 67867469

Change-Id: I41579ba30366e07193ab4f7790e5a107c85d6ec2
/frameworks/base/core/java/android/service/autofill/Dataset.java
5e9e79ccec447b70bd9806316aafbb3d2d1bebdf 20-Oct-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Allow datasets without presentation to optimize authentication use case."
9856b19f4beb19164921de7dd1da638b61e58177 19-Oct-2017 Felipe Leme <felipeal@google.com> Allow datasets without presentation to optimize authentication use case.

Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -t android.autofillservice.cts.LoginActivityTest#testAutoFillDatasetWithoutFieldIsIgnored
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -t android.autofillservice.cts.DatasetTest
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases

Fixes: 36547794

Change-Id: Ibf1d7e45dd2534b6990434db58bc4010f68433ec
/frameworks/base/core/java/android/service/autofill/Dataset.java
3a585a8ef14ffe57fe8addc690d06614f10e2033 19-Oct-2017 Felipe Leme <felipeal@google.com> Improved logging on autofill validators.

Also minor-fixed a javadoc comment.

Test: manual verification
Bug: 67955334

Change-Id: Ieb2265049b0416b3427f63e14e33fb9fa50a16e7
/frameworks/base/core/java/android/service/autofill/Dataset.java
27a026ac1aefe639f41b5c79817abb9ea09a03d3 03-Oct-2017 Felipe Leme <felipeal@google.com> New autofill API: let service explicitly set dataset filter.

Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -t android.autofillservice.cts.LoginActivityTest#filterTextUsingRegex
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -t android.autofillservice.cts.LoginActivityTest#testDatasetAuthFilteringUsingRegex
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -t android.autofillservice.cts.DatasetTest
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases
Test: ran 'm -j doc-comment-check-docs' and checked resulting HTML

Fixes: 67314013

Change-Id: I4412c1bf650219d005b9287033b463de6aee764d
/frameworks/base/core/java/android/service/autofill/Dataset.java
0e60f22d2dd0ad2b30f38f4b55847a239d27eef5 22-Sep-2017 Sunny Goyal <sunnygoyal@google.com> Fixing method asymmetry in Parcel

Test: manually
Change-Id: I2a8321023b40cc74b7026eb0fb32a9cc5f5543a9
/frameworks/base/core/java/android/service/autofill/Dataset.java
9852897bf6a1d4c01ebb5afddaa13be5285810b9 01-Sep-2017 Felipe Leme <felipeal@google.com> New Autofill API: SaveRequest.getDatasetIds()

Test: modified some existing CTS tests to use it
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases

Fixes: 64843801

Change-Id: I95fe7766f19e5a9eea9d7138636a15cc832c704c
/frameworks/base/core/java/android/service/autofill/Dataset.java
d0b18d665ff8a42ccdc46be7a2382c67476c3c7b 25-Jul-2017 Felipe Leme <felipeal@google.com> Don't show Save UI when values filled by user belong to a dataset.

Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases

Fixes: 63068654

Change-Id: Ia9c42d57b0e7c316bfd3c0ee29816db18ac478c1
/frameworks/base/core/java/android/service/autofill/Dataset.java
2ef19c1d73f89ca4718b5a8f0c2e7221621e844f 05-Jun-2017 Felipe Leme <felipeal@google.com> Improved documentation for AutofillService package:

- Moved (and expanded) overall documentation from FillResponse to
AutofillService.
- Improved SaveInfo documentation.
- Improved FillRequest documentation.
- Improved Dataset documentation.

Bug: 37567048
Test: ran 'm -j doc-comment-check-docs' and checked resulting HTML

Change-Id: I157893deac06a5ed5e1cb7fd082da485f227b9ee
/frameworks/base/core/java/android/service/autofill/Dataset.java
a9379d0b44ca1f68a0036d2b65218e17fa348514 10-May-2017 Svetoslav Ganov <svetoslavganov@google.com> Allow null fill values to support authentication case

If a dataset needs to be authenticated the fill service
may not have the values but needs to tell the system for
which fields to show the fill UI. We now allow passing
a null value to mean the view is a part of the dataset
semantically but its value should remain unchanged.

If a dataset has no values, i.e. the related autofill ids
are mapped to null, we cannot properly filter. In this case
we always match such items regardless what the user typed.

While at this improved accessibility support for filtering
to announce when the number of items being filtered changes.

Also while at this allowed a dataset authentication to return
a response which replaces the current response and refreshes
the UI. Matching datasets with null values to any text plus
allowing a response to be returned from a dataset auth enables
the use case where there is always "Import" item at the
end of the list which when clicked can show arbitrarily more
data entries associated to other apps.

Another change is that we now provide the client state
bundle on both request and dataset auth.

Finally, this change gets rid of dataset waiting auth and
response waiting auth concepts since the reference to the
response and the dataset is piped with the auth request.

Fixed a bug where the width of the autofill UI was not
properly measured by going over all items in the adapter.
Now we measure enough height to fit the first three and the
width id the width of the widest item in the adapter.

Test: Added LoginActivityTest#testDatasetAuthTwoFieldsReplaceResponse
Added LoginActivityTest#testDatasetAuthTwoFieldsNoValues
Added LiginActivityTest#filterTextNullValuesAlwaysMatched
All autofill CTS tests pass

bug:37724701
bug:37424539

Change-Id: Ic19e5d7cbdbb7d110c9e7da0ad60b540cbf1aecf
/frameworks/base/core/java/android/service/autofill/Dataset.java
9f9ee25515591ef33281708c0ab911962f4364a6 27-Apr-2017 Felipe Leme <felipeal@google.com> Improved Autofill logging.

- Removed ui.Helper.
- Replaced DEBUG and VERBOSE constants by sDebug and sVerbose.
- Added a shell command to dynamically set the constants.
- Removed obsoleted log statements.
- Changed log-level of some log entries.
- Removed unused methods.

Fixes: 36141126

Test: CtsAutoFillServiceTestCases pass
Test: manual verification

Change-Id: Ic08ee9a2adc10e63f49bbcc7ed126455462dc9c1
/frameworks/base/core/java/android/service/autofill/Dataset.java
cc684ed41f17ccdce45a056fd4034efc35b213d5 17-Apr-2017 Philip P. Moltmann <moltmann@google.com> Add a way to read the last AutofillSelection.

- Check UID to make sure one service cannot read FillSelections of other
services
- Add id to Dataset to allow to tag the datasets. This id is then found
in the FillSelection.Event
- Add clientState to FillSelection to allow service to store more data

Fixes: 36871500
Test: CtsAutoFillServiceTestCases
Change-Id: Ice894245508227265294a1c59ea97842175e5aec
/frameworks/base/core/java/android/service/autofill/Dataset.java
f78e952d8df7074aa7380c5998826a4dffe335e7 05-Apr-2017 Felipe Leme <felipeal@google.com> Removed deprecated auto(F)ill classes.

Bug: 35956626
Test: manual verification
Test: CtsAutoFillServiceTestCases pass
Change-Id: Icb622589c41e6a286d51e3f85bd5a813e483b5ea
/frameworks/base/core/java/android/service/autofill/Dataset.java
f43ca7968fed9fe8862d9b7217c94687dbb12e0a 31-Mar-2017 Felipe Leme <felipeal@google.com> Initial implementation of autofill partitioning.

BUG: 35707731
Test: existing CtsAutoFillServiceTestCases pass
Test: PartitionedActivityTest

Change-Id: If9df5fe63249f0b9e9da058d1c9327dfd3c09cf3
/frameworks/base/core/java/android/service/autofill/Dataset.java
78696bfeb7ac5ae298765bfb9f82cf24d12b7dcc 31-Mar-2017 Felipe Leme <felipeal@google.com> Moar pre-partitioning refactoring.

On ViewState: split value into mCurrentValue and mAutofilledValue.
On Session: replacing mAutofilledDataset by mDatasetWaitingAuth and
ViewState.getAutofilledValue() (mAutofilledDataset is still needed,
but will be removed in the first partitioning CL).

Also fixed a missed 'return' on TimePicker.autofill()

Bug: 35707731
Test: CtsAutoFillServiceTestCases pass

Change-Id: Icc32701ae3e499a77d99e6ae1daa7d070a3df631
/frameworks/base/core/java/android/service/autofill/Dataset.java
24d5893b25ce62b7bc9ed9f35fa72b9d47f23cdd 21-Mar-2017 Felipe Leme <felipeal@google.com> Added a UserManager.DISALLOW_AUTOFILL restriction.

bug: 35710740

Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -t android.autofillservice.cts.LoginActivityTest#testUserRestriction
Test: cts-tradefed run commandAndExit cts-dev -m CtsDevicePolicyManagerTestCases -t com.android.cts.devicepolicy.MixedDeviceOwnerTest#testDisallowAutofill_allowed
Test: cts-tradefed run commandAndExit cts-dev -m CtsDevicePolicyManagerTestCases -t com.android.cts.devicepolicy.MixedProfileOwnerTest#testDisallowAutofill_allowed
Test: cts-tradefed run commandAndExit cts-dev -m CtsDevicePolicyManagerTestCases -t com.android.cts.devicepolicy.MixedManagedProfileOwnerTest#testDisallowAutofill_allowed

Change-Id: I41b2bf9fe3bc8df627c6650960bd11346c430a7e
/frameworks/base/core/java/android/service/autofill/Dataset.java
5311206f3434d631c6ea81ab2e76a46ca18119b6 20-Mar-2017 Felipe Leme <felipeal@google.com> Add custom presentation (RemoteViews) on Dataset values.

New tests on LoginActivityTest:

- testAutofillOneDatasetCustomPresentation()
- testAutofillMultipleDatasetsCustomPresentations()
- testAutofillMultipleDatasetsCustomPresentationSameFields()
- testAutofillMultipleDatasetsCustomPresentationFirstDatasetMissingSecondField()
- testAutofillMultipleDatasetsCustomPresentationSecondDatasetMissingFirstField()

Fixes: 36067706
Test: CtsAutoFillServiceTestCases pass

Change-Id: Iacb660bf5a5cf311dea4bfcbfe1b3722aab34715
/frameworks/base/core/java/android/service/autofill/Dataset.java
82e3793c15298f9c62edee23259c116606f10911 10-Mar-2017 Felipe Leme <felipeal@google.com> Decouple Dataset ids from SaveInfo.

The FillResponse was automatically adding the AutofillId of all Datasets to
the SaveInfo object, but that would cause problems when the AutofillService
is not able to save some data (for example, if it comes from a read-only
backend).

Bug: 36076444
Test: OptionalSaveActivityTest pass
Test: m update-api
Change-Id: I1d5faaddf29e1be0f357438c8485e07caf975293
/frameworks/base/core/java/android/service/autofill/Dataset.java
640f30a7763b0a4b80c767acb84c740aac04768b 07-Mar-2017 Felipe Leme <felipeal@google.com> Replaced auto-fill by autofill to keep it consistent with API style.

This change will affects 2 types of apps: autofill service implementations
and apps that use autofill APIs.

Since just the former is known to be used at the moment, we're not trying
to keep backward compatibility with the latter.

Bug: 35956626
Test: CtsAutoFillServiceTestCases pass
Test: android.provider.SettingsBackupTest pass

Change-Id: Ia720083508716deae9e887f9faa7ae7c5a82f471
/frameworks/base/core/java/android/service/autofill/Dataset.java
eb49515abd2353f32e0eb7b3964847c6399986c9 22-Feb-2017 Svet Ganov <svetoslavganov@google.com> Move the presentation view to proper location.

Test: Auto-fill tests pass

bug:33550221

Change-Id: I041a084800e761859c67b962fb4aefafce8956d8
/frameworks/base/core/java/android/service/autofill/Dataset.java
00c771dc7d8242362f1491ae4ce3efd641235b36 19-Feb-2017 Svet Ganov <svetoslavganov@google.com> Add support for remote views backed auto-fill UI

Test: CTS and manual

Change-Id: Ia09f0208d78439491052e4886a0e71c387b73370
/frameworks/base/core/java/android/service/autofill/Dataset.java
d633f072552815301a559520a1f93eb7e79ba319 14-Feb-2017 Felipe Leme <felipeal@google.com> Minor improvements to help diagnose auth workflow.

BUG: 35348724
Test: CtsAutoFillServiceTestCases passes

Change-Id: I6ad3320faca8eed329b2cc4836281a547f57456a
/frameworks/base/core/java/android/service/autofill/Dataset.java
782043caf81055aa1c331e9cc15b24a10e1bf17a 11-Feb-2017 Svet Ganov <svetoslavganov@google.com> Refactor auto-fill

* Fix a layering issue where auto-fill manager which is in view
depended on activity which is in app

* Moved auto-fill classes to view or service based on their
purpose and removed dependecy on the classes in view to the
classes in service

* Push state to local auto-fill manager whether auto-fill is
enabled to avoid making IPC for every focus transition if
the user did not enable the feature

* Remove unnecessary offload to messages when handling calls
to auto-fill manager service as these are made over a oneway
interface and in general they do almost no work and typically
we do these on the binder thread

* Removed id from data set and fill response as the provider
can embed everything it needs to id them in the auth pending
intent

* Enforce the auth UI to be only an activity as this will work
with multi-window, recents, and back and also does not require
draw on top of other app special permission

* Authentication also no longer requires passing a remotable
callback to the auth activity but the activity handles the
request as if called for a result

* Handling stopping of a user to clean up in-memory state as
well as handling when a user gets unlocked as a provider may
be non-direct boot aware

* User the correct context when creating an auto-fill manager

* Move the receiver that listens for requests to hide system
windows to the manager service as the UI is a singleton and
no need every per-user state to register its own

* Removed extras from dataset as the only case a provider needs
to associate state with a dataset is for auth and the provider
can embed this data in the auth pending intent

Test: manual and CTS

Change-Id: I4bc54c13cf779d7f6fdb3ab894637f9fac73f603
/frameworks/base/core/java/android/service/autofill/Dataset.java