Attach the keywords used for Settings search to Slices.
Their primary use is helping match synonyms for presenters
which display slices without explicit Uri requests, like a launcher.
This changes:
- Updates database scheme
- Adds to SliceData object
- Grab keywords in the SliceDataConverter
- Set keywords on all slices
Test: robotests
Change-Id: I16c40d2380ffddaf0a87fb1b9cd58e95573b308f
Fixes: 78306195
getDescendants allows another app to collect a list
of all valid Uris for Settings Slices. Important for search,
assistant or launcher apps.
This means searching our database for all valid keys and building
a list of Uris for each of those keys.
Fixes: 77808328
Test: robotests
Change-Id: I3ae27e4661a7dcaab50b091ae2730013118af8a2
Add AccessibilityPreferenceController, which wraps all a11y settings
since they are share common infrastructure for enabling, current value,
and availability.
We add an overlay for OEMs to declare their bundled a11y services.
This is the only list of services that will be possible to enabled via
Settings slices.
Accessibility Slices are built by getting a list of valid services,
and indexing the service names as a key in the Slices DB. When they are
built at runtime, they use the generic A11yPrefController to get the status
and enable/disable the service.
Bug: 67997836
Bug: 67997672
Test: robotests
Change-Id: I66f905bf1c55eecb937945c4675c12bcbc96d698
PendingIntents were being cached because they had the same
targets and would not differentiate on extras - thus all Slice
intents would go to the same destination as the first intent fired.
Adding the data stops the system from caching the intents.
Change-Id: Ifccab72ed482e22750422c5c36aa6d205c20ae3d
Fixes: 77650727
Test: robotests
In the change to mark disabled_dependent as available,
it did not change the check in SliceBuilderUtils for the
unavailable Slices. In the case of DISABLED_DEPENDENT, the
setting is available but the Slice is not.
Though it is a simple change, we can now properly test the contents
of Slices, so this change includes tests which should have been in
place earlier and would have caught this bug - duh.
Bug: 71640747
Test: Robotests
Change-Id: I8db5bc80edb337cbf907ce3669aa2bfd9c72f74a
If both Xml and a controller provide a summary,
the controller's should be prioritized.
Change-Id: I030746b0f253ce4884a7868e385069b208f63082
Fixes: 77602860
Test: robotests
When an inline slice is requested, and the setting is unavailable,
we should present more useful information to the user. This CL handles:
- Unsupported: return intent slice to Settings home page
- Disabled for user: intent to the setting page
- Unknown reason: intent to setting page
- Disabled dependency: Create intent-based Slice rather
than the requested inline slice.
Bug: 71640747
Test: robotests
Change-Id: I9c1a0ee36119d4f9f3b205e0824c251f4356db55
Extend slices_index.db to include SliceType and platform flag.
This will be used when we generate a list of all available slices
for different authorities & separated intent/action paths.
Bug: 62807132
Test: robotests
Change-Id: I1cce49d077c02ab79153db9bfdfc894dbab5e16a
Create the notion of an official platform slice.
This includes:
- Adding a second authority to the provider
- tagging slices in xml with a platform slice flag
- Including authority in the getUri method
Bug:73359139
Test: robotests
Change-Id: I5382be138a262dbc5a8324c34aab131c5d0d5516
Merged-In: I581ee6dfcdf935f452a15e89e5d055e375ff1877
Add a getter for Slice type for BasePreferenceController.
This facilitates the generation of all possible Slices for Settings
search and discovery for AGSA.
Bug: 62807132
Test: robotests
Change-Id: I2cba1fc72c95769ecc26c76d1f2faa49a285d077
Return CharSequence instead of String.
All user visible string should be modeled as CharSequence.
Bug: 73950519
Test: robotest
Change-Id: I30befef0c33f94351d4a2774e283bd1ed804aa8b
To add bluetooth as a valid slice requires adding
support for Context-only preference controller
constructors, which was already planned work.
Fixes: 67997327
Test: robotests
Change-Id: I7efd20a05d5796c3327a26b1fc535d5436d1070f
Summary on slices will now determined by checking that
summaries in the following order are valid:
1) SliceData summary
2) Preference Controller summary
3) SliceData screen title
Valid is currently defined as:
- Not empty / null
- Not whitespace
- Not sumamry placeholder
Fixes: 71640678
Test: robotests
Change-Id: I5e699e8566ece80742d311617b7dc4e9a9bda8cf
Connect the SliceIndexing data to the SliceProvider,
such that a query to SliceProvider can build a Slice
via the indexed data from SlicesIndexingManager.
We take the key from the Uri supplied to the SettingSliceProvider
and find a potential matching row in the indexed data. The
matched data is then used to Build a slice for the caller.
Bug: 67996923
Test: robotests
Change-Id: If51bfd1a05c3f3817ae720554f95a98fc7b002e1