Commit Graph

46 Commits

Author SHA1 Message Date
jackqdyulei
bdc4ea6336 Add feature provider for bluetooth settings
Also add method to get settings uri for specific device. Use feature
provider here because it give us more flexibility.

Bug: 120803703
Test: RunSettingsRoboTests
Change-Id: I6f4840e76279c02a75b95fdecd822a72cb0b42e5
2018-12-18 14:42:49 -08:00
Kevin Chyn
9ed7cb40cb Get enrollment animation from overlay
Bug: 111548033

Test: Able to get animation from overlay
Test: atest RunSettingsRoboTests

Change-Id: Ib02f484474b306ba8d61f9be541acb12dd1ecd90
2018-12-14 18:02:54 -08:00
Raff Tsai
da7a5d1171 Add log feature
- Add ContextualCardFeatureProvider to handle card interaction

Bug: 79698338
Test: manual
Change-Id: I2a76f5ccfd07072a98ee927bed7dc39731d4cb09
2018-11-30 06:41:22 +08:00
Matt Fritze
90899e08f0 First commit for settings panels
Establish the Activity which hosts Settings panels through the
PanelFragment. The Activity's purpose is to validate the intent
data coming in, including:
- Called with startActivityForResult (so we can log who is calling)
- Intent has the proper intent extra to link to a Panel

The fragment takes the Panelable data and builds a Settings Panel.
Each panel will have:
- Title
- List of Slices
- Link to underlying content

The Panelable interface is created to provide all of those datums, and
the new FetureProvider provides the Panelables by linking them with
keys. The keys will eventually become public APIs with CTS tests.For
now, we store them locally.

I included an exmaple panel, the InternetConnectivityPanel which
currently shows Wifi and Airplane mode.

Screenshot: https://screenshot.googleplex.com/c6sv7ZzQ5OJ
Bug: 117804089
Test: make -j40 RunSettingsRobotest
Test: Manual app
Change-Id: I1932f7179cc32088acd6413a736901ddf9651892
2018-11-26 15:26:02 -08:00
Fan Zhang
6632529ba1 Remove DeviceIndex feature/service.
Change-Id: I8444101669aef013183842c2d13cf3960c756398
Fixes: 112587202
Test: rerun all tests
2018-10-08 13:47:07 -07:00
Fan Zhang
37f805a192 Remove BluetoothFeatureProvider and impl
It's not used by anything

Change-Id: I03a73461a391657b8efbce13670a0c92fc4e3565
Fixes: 111940586
Test: rebuild
2018-07-30 11:00:04 -07:00
Ivan Chiang
f2f03b8198 Add DockUpdaterFeatureProvider and DockUpdater.
Add the new feature components for dock devices.

Bug: 77931823
Test: Build
Change-Id: I219a5256d02f2b1b8ea7cce1cff4219975f2eae2
2018-04-19 16:04:08 +08:00
Jason Monk
f6edc7c80a Add option for settings to push to a device index
The index implementation is optional and left up to the OEM.

Test: Open settings, see content in index
Test: robo tests
Bug: 68378569
Bug: 76102600
Change-Id: Idb8bb1e0cabbbe92e7a852e2eadbdcd8c2ab7d56
2018-03-23 09:36:57 -04:00
Leslie Watkins
58eb43a2e4 Remove all reference to SmsMirroring in Android Settings.
Test: Robotests

Change-Id: I3318c6915cae95522f09838f00a3c567fe9e5fc5
2018-02-12 22:05:56 +00:00
Fan Zhang
3ed55b1450 Remove dead code for DataPlanUsageSummary
This is an unfinished feature, no longer needed.

Change-Id: I358dcc8865184117d49e35b3e8dfcd84403261d0
Fixes: 73073608
Test: rebuild
2018-02-07 20:35:56 -08:00
Leif Hendrik Wilden
28dee1f086 Migrate to use instrumentation classes from settingslib.
Test: Compiles. Manually tested.
Change-Id: I70a6e76cc8440547746ecc008c32bd06a7de8161
2018-01-24 12:30:39 -08:00
TreeHugger Robot
06af7c8d4b Merge "Add a new About Phone page." 2018-01-23 07:04:29 +00:00
Daniel Nishi
1e620957b8 Add a new About Phone page.
This adds the "Me Card" page. The current functionality is to show
information based upon the first account added to the system. The page
shows the user's avatar, name, primary account, and phone number.

Bug: 63819909
Test: Robotest

Change-Id: I64bfae922e828994b2b87009d0647e67dab0da42
2018-01-22 17:21:10 -08:00
Leif Wilden
cab0ee611d Revert "Migrate to use instrumentation classes from settingslib."
This reverts commit 1546cca529.

Reason for revert: Broke fingerprint setup flow. b/72267201

Change-Id: I8321265ae64732c526325882ddea51080decddf5
2018-01-22 20:57:36 +00:00
Leif Hendrik Wilden
1546cca529 Migrate to use instrumentation classes from settingslib.
Test: Compiles. Manually tested.
Change-Id: Ie5515bb0fe3e621fc7723a9b04ba23e4bfa9c401
2018-01-18 11:13:24 -08:00
Matthew Fritze
13c43f1900 Index Data to build Slices in Settings
The indexing is done by taking the indexable fragments from
search, grabbing their XML via SearchIndexableResources, and
then looking for controllers defined in preferences.

For each controller found, we take the combination of the
fragment providing the XML and the Preference info to create
an indexable row.

Buiding a Slice will be handled in a subsquent CL, but a
prototype can be found here: ag/3324435

Test: robotests
Bug: 67996923
Change-Id: I48668618079bcc3da55ab77b7323ee8e467073af
2017-12-19 09:47:07 -08:00
Oren Blasberg
d33dcf13ee Settings: Add SMS Mirroring.
Bug: 37546615

Test: Updated Robolectric suite with new unit tests.

Change-Id: I02e1723e1b125b004ff679d6242df14bca4f08ce
2017-07-19 08:07:11 -07:00
Rajeev Kumar
ad157aca52 Create a feature provider for data plan feature. This change will
allow us to enable/disable this feature from adb shell.

Bug: 62349208
Test: make RunSettingsRoboTests -j40
Change-Id: I2d0bed738d5d4cd0fe1de056ee37092d46be72b6
2017-07-05 12:25:53 -07:00
Matthew Fritze
2078bc2358 Remove search2 package and put everything into search
Change-Id: Ie8651c79ef023f154cd7120a88a20f3481abce2b
Fixes: 38502743
Test: make RunSettingsRoboTests
2017-05-23 13:57:28 -07:00
Fan Zhang
d7414259d0 Move entity header controller out of application package.
Bug: 37669238
Test: rerun robotests
Change-Id: I54eb30f28fa0a88a6f0b97b53f9f1408320b5ce0
2017-05-18 16:36:32 -07:00
jackqdyulei
3db59a8430 Add feature provider for Bluetooth
Also add method to check whether pairing page is enabled.

Bug: 38134564
Test: RunSettingsGoogleRoboTests
Change-Id: Ib74ece46f9624242895a366eac889957924f84c6
2017-05-08 16:06:42 -07:00
Denis Kuznetsov
f0a61dd112 DO Disclosures: detailed application lists
Add UI that lists enterprise set default apps for handling important intents
(opening browser, using camera, phone, etc).

Bug: 32692748
Test: m RunSettingsRoboTests
Change-Id: I75bb97d1b3728b1dcb90981b24d12edf510c4b04
2017-04-25 16:53:17 +02:00
Soroosh Mariooryad
5f375a2776 Move suggestions package to dashboard.suggestions
Test: RunSettingsRoboTests

Change-Id: I4f9af27767c8e55d3b1a16e77c099da52d40aab5
2017-02-24 11:04:41 -08:00
Soroosh Mariooryad
e457e35ec0 Add ranking to SuggestionFeatureProvider interface.
Test: RunSettingsRoboTests
Fixes: b/35363662

Change-Id: Ib786e6b2733e2b151f73fb68e174a21aedb2b20a
2017-02-20 17:34:36 -08:00
Philip Quinn
a9831d40d0 Add settings for the assist gesture.
Availability of the gesture is gated by a new FeatureProvider.

Test: make -j RunSettingsRoboTests; manual test on
      supported/unsupported configurations.

Change-Id: I3529367a73e33370d5112b91d5144293ffa7fa22
2017-02-14 16:45:23 -08:00
Fan Zhang
6f7164c5a9 Add SuggestionFeatureProvider interface.
The feature provider will contain all logic for suggestions.

Test: RunSettingsRoboTests
Change-Id: I45a0dcdc101d97acb07babd531db50b80bb3b308
2017-01-19 10:15:35 -08:00
Shahriyar Amini
4774b58b4c Dynamically update injected security preferences.
Bug: 31002801
Test: make RunSettingsRoboTests

onResume will dynamically update injected security preferences with data
from the associated tiles.

Change-Id: Ibf46abdfcff27bd1b00729fe815c3cf3ace64e26
2016-12-29 12:04:47 -08:00
Matthew Fritze
9955db6360 SearchFeatureProvider's context field is removed
SearchFeatureProvider was holding on to a context and
outlived the SettingsActivity, thus leaking the activity.
The context was passed into most methods, and thus it
makes more sense to pass it in to every method.

Bug: 33677967
Test: Run MakeSettingsRoboTests
Change-Id: Ia82f30e7e0b83587b4baeef28e81da6b8e4303fe
2016-12-20 11:39:10 -08:00
Jaewoong Jung
1e0f8ff5e5 Adds a menu item for additional battery info to battery settings.
Bug: 33352540
Test: No additional test failures.

Change-Id: Ibfc1a9463c93d3c087ed712fe45d3d0717472c6a
2016-12-16 12:25:32 -08:00
Salvador Martinez
980f575955 Added feature for surveys provider to Settings
It is now possible to create and show surveys to a user
asking them for feedback within the Settings app.

Test: JUnitTests
Bug: 27823357
Change-Id: I824899045f6ce30e5b6f46d20888da673114f658
2016-12-05 15:42:07 -08:00
Matthew Fritze
0ed37c3513 Fork Search code to independantly develop and test search.
This is the start of the new search in Settings. It is a nearly complete
replacement of the old search code in a more modular and flexible
architecture. It is expanding the datasources that it queries, including
the same Settings database, which will now include more first party apps
and be extended to support inline results where the user can change
settings directly from the search view. Search will also fan out to
query new sources (local or remote), and is built in a way
such that adding additional sources is roughly the same amount of work
had they been added in the initial writing of this code.

Query interpretation will now be source-dependant, allowing for future
upgrades to fuzzy search where it is applicable.

Change-Id: Ib0bac1fe92bf8a662d33abf9a99bb6ee2090ec8f
Fixes: 32115225, 32378927
Test: make RunSettingsRoboTests
2016-11-17 14:34:29 -08:00
Bartosz Fabianowski
05061fced3 Add Enterprise Privacy page to Settings
This adds a new page to Settings which tells the user about his/her
privacy in light of enterprise management. The new page is only shown
on devices that have a Device Owner app set.

This CL adds a mostly blank page. Follow-up CLs will populate the page
with information about specific admin actions/policies.

The page's title ("Privacy"), icon and location in the Settings app are
tentative. The page will move to its final location once the new IA
redesign is finished.

Test: make RunSettingsRoboTests
BUG: 32692748

Change-Id: I5b5c08c0025207516b0779f54cf68234a4ba3fe4
2016-11-14 12:04:49 +01:00
Fan Zhang
c9536b8e41 UI Refresh: a new app info header for app/notification.
- moved force stop and uninstall button to bottom of page (as footer)
- Forked appheader layout file, and created AppHeaderController to
  contain all binding logic for header.

Bug: 32442716
Test: RunSettingsRoboTests
Change-Id: Id4eb365ca25e035c043c068867f5cbc3a202b201
2016-10-27 13:48:13 -07:00
Fan Zhang
e0c253fccb Add summary provider for system tile.
Refactored getLocaleNames() into a FeatureProvider interface so it's
reusable and testable.

Bug: 31801428
Test: RunSettingsRoboTests
Change-Id: I2d31a66a4b32cfa7a364a4cfef1f6eea87084577
2016-10-14 11:08:51 -07:00
Fan Zhang
e6c60c24a8 Add test for new DashboardFragment and PreferenceController
Also added a FakeFeatureFactory to make it easier to mock different
FeatureProviders.

Bug: 31781480
Test: make RunSettingsRoboTests
Change-Id: Ie45db601e0bec951d7ef983ec2e3ca747ec1c3af
2016-10-06 10:33:01 -07:00
Fan Zhang
a96a2d8d60 Use DashboardFeatureProvider to load homepage tiles.
Adding support to homepage category.

Test: SettingsRoboTests for regression. Will write tests for new feature
soon once we are set on the data structure.
Bug: 31781480

Change-Id: I25fa367fecb643f17e23f0182df7585bf1fcdd02
2016-09-29 12:31:10 -07:00
Fan Zhang
488033e54d Add feature provider for dashboard.
The feature provider contains API that controls whether a new
information architecture should be used. By default it's false.

Bug: 31768091
Test: make RunSettingsRoboTests
Change-Id: I5b177be418def50d877f53dc799e42d06eba95ec
2016-09-27 11:25:27 -07:00
Fan Zhang
66a9852a7b Extend MetricsFactory so it can log to different LogWriters
- Renamed MetricsFractory to MetricsFeatureProvider, and access it using
  FeatureFactory.
- Instead of containing exactly 1 logWriter, MetricsFeatureProvider now
  contain a list.
- Added OnAttach event in Lifecycle. This is needed when a mixin
  requires Context to initialize itself.
- Updated tests.

Bug: 29575437
Test: make RunSettingsRoboTests
Change-Id: I7cc1528b9a744cd40088701e2bd115f41a8bf744
2016-09-15 14:25:31 -07:00
jackqdyulei
348bcc1e81 Add the interface to check the status of location setting.
Bug: 30790766
Test: ag/1346969

Change-Id: Id6de284ba90f75015372dbe28805bdc0d94a0723
2016-08-31 12:54:17 -07:00
Daniel Nishi
aad643caf2 Remove the Deletion Helper and Automatic Storage Management jobs.
The automatic storage management settings have been left in place
and updated to use the intent to get into the deletion helper.

Bug: 28965462
Change-Id: I736c8e741b519eceb89075b74d42b38c3aa5d0f4
2016-06-21 10:00:52 -07:00
Daniel Nishi
80c204420b Add an automatic storage management job service.
This service runs once a day when plugged in when the device has
under 15% free space remaining. If the FeatureFactory has a
storage management job, it runs the job to begin to free up space
on the device.

This is a temporary landing place and will be refactored very
quickly out of Settings.

Bug: 28600825

Change-Id: Id2ebb42a333b3b4e3daef4e50cf985fe055b85c7
2016-05-31 16:50:48 +00:00
Daniel Nishi
38889de699 Create an overlay to add a photo and video deletion helper service.
This overlay defines a checkbox preference in the deletion helper for
facilitating the deletion of photos and videos. The service which
provides deletion clearing can be overridden and used to create a
custom photo and video deletion helper.

Bug: 28554187
Bug: 28560856

Change-Id: Id5d9671a307aaac0d1331f055b8f2ab7aa67977c
2016-05-10 10:48:59 -07:00
Fan Zhang
a9fa0059b2 Add c2c and chat support when there is eligible account.
Bug: 28141203
Bug: 28316618
Bug: 28316343

- Replaced hardcoded fragment layout with a RecyclerView. The old layout
  was essentially building a list manually.
- Tweaked layout to look better.
- Hide escalation cards when there is no account. Show cards when
  there is at least 1 account.
- Request an intent to start specified support type when card is
  clicked.
- Monitor account changes so we can hide/show escalation cards when
  add/remove account.

Change-Id: Ie48158b85ade1363a41817cc88b1193e0aef87ae
2016-04-27 09:06:17 -07:00
Fan Zhang
2869157ba9 Display setting and support in a tab layout - DO NOT MERGE
Bug: 28269035
Bug: 28139604
2016-04-20 11:42:15 -07:00
Andrew Sapperstein
1d1a2694e9 Remove ToastController.
Wasn't meant to be submitted.

Change-Id: Icc94daaf47ed85cefb59f20928241ef38d5ee2ca
(cherry picked from commit 17047d1939)
2016-04-20 16:54:13 +00:00
Andrew Sapperstein
13792886a7 Create feature factory interface & initial impl.
Creates the abstract class FeatureFactory and an AOSP implementation
called Factory.

Also creates a static library for generating logtags since we need to use the code generated
by the logtags in multiple packages now.

BUG: 27751878
Change-Id: I88d826333642d3efc252134c4facb7b1ca014f32
(cherry picked from commit 867bb9c07a)
2016-04-19 23:01:49 +00:00