Commit Graph

374 Commits

Author SHA1 Message Date
TreeHugger Robot
c9f1d89dd3 Merge "Remove dead code for DataPlanUsageSummary" 2018-02-08 06:21:11 +00:00
TreeHugger Robot
682bb3e8e5 Merge "Add feature flag for new DataUsageSummary fragment." 2018-02-08 04:55: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
Eric Schwarzenbach
98998a2fcc Add feature flag for new DataUsageSummary fragment.
Creates a new fragment DataUsageSummaryLegacy, which is used
instead of DataUsageSummary when the feature flag is off (default
behavior).

Copies the current DataUsageSummary.java, data_usage.xml, and
DataUsageSummaryActivity to create the legacy versions. This
change allows for uninterupted development of new features in the
DataUsageSummary fragment.

Test: manual
Test: make RunSettingsRoboTests
Bug: 70950124
Change-Id: I9d79e108bbfc1c8ec620f86c0183f4ed3f41c9d7
2018-02-07 14:29:41 -08:00
Fan Zhang
f11c885766 Pre-fixup for nav up button
- Remove SettingsDrawerActivity.EXTRA_SHOW_MENU and force up nav button
  to always show. The button doesn't do anything yet. It just finishes
  current activity.
- Remove dead code about suggestions

Change-Id: I61fa9fefbaa9bced841a05969544b1c824c564ce
Bug: 72337421
Test: rebuild
2018-02-07 10:27:18 -08:00
Fan Zhang
6013a95b9e Misc fixes on settings search
- Remove some unused resources
- Disable contentDescription on search icon in homepage

Change-Id: I214b2be3db4fe4c12932763acfb40b6272b43600
Fixes: 72958338
Test: talkback
2018-02-06 12:25:14 -08:00
Fan Zhang
73dc479ab5 Remove security settings v1 code
Change-Id: I958ed1588009b91f64cd8ecb98208e72a891903e
Fixes: 32953042
Test: robotests
2018-01-29 13:17:05 -08:00
Fan Zhang
881d579620 Misc fixes for User page and my device info page
- Rename UserAndAccountDashboard* to AccountDashboard*
- Move emergency info from account to device info page

- Move auto sync data toggles (4 of them) from Account page to user page
   - Move the controllers too. UserSettings is a not a DashboardFragment
     so I had to manually call each controller method.
     TODO: refactor UserSettings to a DashboardFragment

- Move legal information/regulatory info above advance button within device info page.

Fixes: 72523158
Bug: 71871075
Test: robotests
Change-Id: I1b8af8af61e49d17926f984978a09a974b6c62e1
2018-01-26 12:39:34 -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
Fan Zhang
f314494f32 Fork SecuritySettings page and hide behind a feature flag.
Bug: 32953042
Test: robotests
Change-Id: Ibbb4221eef87f09ccd024146517707680180a100
2018-01-02 13:42:53 -08:00
jackqdyulei
166102c3c0 Add feature flag for battery settings page.
Create PowerUsageSummaryLegacy and power_usage_summary_legacy, which
contains the old implementaion.

Bug: 69797586
Test: RunSettingsRoboTests
Change-Id: Icb9c25f06889462a6eedea48ae166043a6636848
2017-12-05 13:15:13 -08:00
Fan Zhang
e096ae7acb Change style of search bar text to allow OEM costomization.
Change-Id: I78dbe6780e3a4adefe82a36400d9fff8c1de92e3
Fixes: 68814716
Test: visual
2017-11-30 14:51:27 -08:00
TreeHugger Robot
03b2d4c44c Merge "Disable DevelopmentSettingsActivity by default" 2017-11-23 01:47:53 +00:00
Fan Zhang
831f6302ee Disable DevelopmentSettingsActivity by default
And if for any reason monkey user is able to enter develop option page,
we show nothing.

And update some test to sdk 26.

Change-Id: I3f985e7fe14bd290db73b8c46dd817591df02015
Fixes: 68707778
Test: robotests
2017-11-22 14:44:23 -08:00
jackqdyulei
76ba0f72e4 Add feature flag for connected device
Add feature flag to toggle connected device between new and old
feature.

ConnectedDeviceDashboardFragment will contain new feature will
ConnectedDeviceDashboardFragment2 will hold old feature.

Bug: 69333961
Test: Build
Change-Id: I0ea932c69dea5242129aab994d5142b1f87fbea0
2017-11-20 15:29:28 -08:00
jeffreyhuang
cb823d5983 Delete DevelopmentSettings.java
- Remove the old DevelopmentSettings
 - Remove references to the feature flag

Fixes: 65522949
Test: make RunSettingsRoboTests -j40
Change-Id: Ie2eb3465127d79a027de6bb58a47bb15e3094f89
2017-11-17 13:52:33 -08:00
Doris Ling
4a01283309 Remove the feature flag for using new title.
- remove all code that check for the feature flag, and use the new logic
by default.

Change-Id: I7fbe60da84c1c0f35e7241402a71d2bc4cd300e6
Fixes: 64564191
Test: make RunSettingsRoboTests
2017-11-13 17:58:13 -08:00
Fan Zhang
ff4da23a65 Create a feature flag for Search v2.
Also moved all other flags in a common file so we can track them more
easily.

Bug: 68825426
Bug: 64938328
Test: rerun robotests
Change-Id: I3fc805054cb960bedd965b1b907be759df50b95d
2017-11-09 14:57:08 -08:00
Doris Ling
1a6887bbd3 Set activity title from preference screen title.
- When we initialize the preference screen, if the screen title is
available, use that to set the activity title, so that it will be up to
date with dynamic language changes.
- for preference fragment that don't have preference screen xml, added a
getTitle() method for the fragment to provide the title explicitly.
- use feature flag to switch between the old and new mechanism for
handling activity title.

Bug: 64564191
Test: blaze-bin/screenshots/android/i18nscreenshots/i18nscreenshots
Change-Id: I96318a5aa81e7b8ca94118adac3245ed27a03d93
2017-10-20 22:46:12 +00:00
jeffreyhuang
142682c19c Hide dev options v1 under feature flag
- Cutover to DevelopmentSettingsDashboardFragment
 - Add dev_option_v1 feature flag

Bug: 34203528
Test: make RunSettingsRoboTests -j40
Change-Id: I2ff7b5c55f1f27cd24b4e276d3d81a73f67dcf88
2017-10-17 13:49:19 -07:00
Fan Zhang
a8cac7a409 Move ManageApplications to sub package and remove dead code
Bug: 64804294
Test: rerun test
Change-Id: I23cbd8da9b65f52470030ba3b9b676ece2bada11
2017-10-12 13:48:54 -07:00
Fan Zhang
4c26da9e13 Fork a new developer options page.
- Create a new activity/fragment and add it to manifest
- Mark old activity/fragment deprecated
- Enable/disable the new activity based on FeatureFlag
- Initial skeleton code for new fragment

Bug: 65522852
Test: make RunSettingsRoboTests -j40 ROBOTEST_FILTER=DevelopmentSettingsDashboardFragmentTest
Change-Id: Ib1395693f8b6f61d4726573a9ea841ea53cf207b
2017-09-10 15:02:51 -07:00
Fan Zhang
3f6c90eb34 Merge "Delete DynamicindexableContentMonitor & all refs to it" into oc-mr1-dev am: 5b820431d3
am: a8f7f745e1

Change-Id: Ifd5618ddad3fcc9a535fe719470e67946bcd9d2d
2017-08-10 02:30:57 +00:00
Fan Zhang
e3535d9998 Delete DynamicindexableContentMonitor & all refs to it
Convert input device search into a search query loader

And remove old logic from DynamicIndexableContentMonitor

Change-Id: If652b1ea7c8add9185bbd025055e14925d3a8eec
Bug: 64310452
Bug: 63831980
Test: robotests
2017-08-09 17:27:02 -07:00
Tony Mantler
3d84d56336 Remove development settings prefs file
Move DevelopmentSettingsEnabler to SettingsLib

Bug: 64159590
Test: DevelopmentSettingsEnablerTest
Change-Id: Id609266019e05a3e06b4ee3bc10de9c019628a42
2017-07-31 14:01:09 -07:00
Rajeev Kumar
4a5e3dc6c5 Data plan usage summary activity.
Change-Id: Ibb0889563d432591fd00ac00d03633b1894ad124
Note: These changes are required for Data balance UI.
Bug: 62349208
Test: make RunSettingsRoboTests -j40
2017-07-19 12:35:24 -07:00
Fan Zhang
2ea6700336 Show default app icon in default app screen.
- Renamed AdvancedAppSettings to DefaultAppSettings.
- Add logic to DefaultAppPreferenceController to also display icon.
- Modified DefautlAssistPrefController to suppress gear icon, and use
  the controller in default app setting UI to display icon.
- Remove dynamic injected payment setting activity and create the
  setting statically in xml.
- Add DefaultPaymentSettingsPreference to display default payment app
  title (no icon because we can't get it)

Change-Id: I6b8c768da0bafe5ec9a85ba9c79c7993b449be25
Fix: 36458534
Test: robotests
2017-07-13 13:49:28 -07:00
Fan Zhang
aeb94f0e5c Fix race condition and optimize categoryUpdater refresh
- In SettingsActivity, do not call updateCategories() if nothing
  changed.
- In SummaryLoader, create a mapping between tile key and summary. This
  is necessary to handle a race condition where category is refreshed
  after summary load.
- In DashboardSummary, refresh Tile's summary to latest cache value
  everytime category is refreshed.

Change-Id: I61389b8ba614ba7e34939325bada6e1bd6fa6709
Fix: 63149109
Test: robotests
2017-07-06 10:13:58 -07:00
Andrew Sapperstein
c217464dca Dashboard search bar polish
Various tweaks to match redlines:
- background is now grey all the time
- the search icon is aligned with the other icons
- the title text is primary colored instead of accent colored
- the background of search bar doesn't scroll anymore

Deletes a bunch of logic to add an initial view that would be
colored based on the first view. It never quite worked right.
Now it's consistent and never moves.

Bug: 37477506
Change-Id: I82c584e8f8ecc6fc298c5cdbce08516c6a069a39
Fixes: 62267378
Fixes: 62379978
Fixes: 62361213
Test: robotests
2017-06-26 10:08:44 -07:00
Andrew Sapperstein
a2dd9978d4 Remove logic for adding a search icon to action bar.
No longer used given that we don't show the search icon on any page.
The main settings page now has the search bar.

Change-Id: I9535028298739467e7fa9c75d1a2fb2b2fa3251b
Fixes: 62230804
Bug: 37477506
Test: robotests
2017-06-25 13:51:08 -07:00
TreeHugger Robot
fca1b78d94 Merge "Initial search bar implementation." 2017-06-01 06:43:22 +00:00
Christine Franks
c101dda9f7 Merge "Allow FR in carrier demo mode" into oc-dev am: 9ef166a578
am: d974ccb625

Change-Id: I8d693fd2d41f73b53416ee83d7b289496765c660
2017-05-31 22:54:31 +00:00
Andrew Sapperstein
048f6fb8b3 Initial search bar implementation.
Replaces the default Toolbar in SettingsActivity with one that looks
like a search bar. It uses a Toolbar inside a CardView with some custom
styling.

Since the search bar is a floating element, the new toolbar lives in the
content frame of the dashboard. A FrameLayout is used to provide the
layering that is desired.

Since the search bar is on top, an additional spacer view is added to
the list of items in the dashboard. Its color changes based on what
the first view is so that it always matches.

Adds android-support-v7-cardview as a dependency (and reorders the
other deps to be in alphabetical order).

Remaining work (in future CLs):
- remove search menu option?
- clean up initial window
- remove the line between the header and the first condition
       when there's a condition

Bug: 37477506
Test: make RunSettingsRoboTests
Change-Id: Id7477b90fbaf30eb5cac1ee244c847bddb95b3fd
2017-05-31 15:24:25 -07:00
Christine Franks
2d0293951a Allow FR in carrier demo mode
Bug: 62133292
Test: make RunSettingsRoboTests -j100, and manually verified FR is
available in carrier demo mode.

Change-Id: Ia793bf234b229da0490accfea6d44b72395a04bc
2017-05-31 12:04:01 -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
Matthew Fritze
ab0b3f6790 Prevent race conditions after dropping database
Block all loaders from accessing the database
before indexing is complete.

Bug: 37501479
Test: make RunSettingsRoboTests
Change-Id: I2af98dcf6bceacbeffa70bd40879c97bb0cbc828
Merged-In: I02f8423c0ffc27abbb8ceb61a8c47d2f0796d0bb
2017-05-08 18:48:04 +00:00
Matthew Fritze
be0989cc61 Prevent race conditions after dropping database
Manual merge from: ag/2155898

Bug: 37501479
Test: make RunSettingsRoboTests
Change-Id: I02f8423c0ffc27abbb8ceb61a8c47d2f0796d0bb
2017-05-05 15:30:39 -07:00
TreeHugger Robot
190b560c9a Merge "Search Icon persists through screen rotation" into oc-dev 2017-04-14 05:25:57 +00:00
TreeHugger Robot
5569816021 Merge "Keep EnterprisePrivacySettingsActivity always enabled" into oc-dev 2017-04-01 05:17:10 +00:00
Matthew Fritze
7d48ae808a Search Icon persists through screen rotation
Change-Id: If88d345f4ce61f6aec1599d0db85cbfa3b8e91c3
Fixes: 36457675
Test: make RunSettingsRoboTests
2017-03-30 18:18:17 +00:00
Bartosz Fabianowski
578b02f33c Keep EnterprisePrivacySettingsActivity always enabled
The existing code checks during Settings startup whether the device is
managed. If it is not, EnterprisePrivacySettingsActivity is disabled.
If the device then becomes managed, Settings will not notice until
the next restart, causing any attempt to launch this Activity via an
Intent to crash.

This CL changes things so that the Activity is always enabled but
simply does nothing when launched on a non-managed device.

Bug: 34122104
Test: Integration test coming in a separate CL
Change-Id: I0a1dfcb41b405d981309696d97678df6787b4f72
(cherry picked from commit 92d25fb5f3)
2017-03-30 08:28:02 +00:00
Matthew Fritze
8a42b074a7 Reserve full indexing for SearchFragment
Full Index should only be accessible from Search Fragment,
and when only full index should declare a locale to be
indexed.

Test: make RunSettingsRoboTests
Fixes: 36656637
Change-Id: Ie673067118ac6b184570e116ea24a169be027053
2017-03-29 23:55:48 +00:00
Fan Zhang
11d2d68e23 Move developer options related class to development package
Bug: 34203528
Test: none, purely moving classes around
Change-Id: I3cd1d257f948729fda5c04632e7ce9114c40bd0c
2017-03-17 16:51:21 -07:00
Fan Zhang
7c8f8a0a41 Attemp to fix a concurrent modify exception
Change-Id: I039091d43ba8c378066c26dcca416534d0f52d21
Fix: 36347434
Test: existing tests pass
2017-03-17 12:54:24 -07:00
Matthew Fritze
0b431fc003 Purify SettingsActivity from old search code.
Bug:35763944, 32590887
Test: make RunSettingsRoboTests
Change-Id: Id8140b68a676e595bff095546fa119cd3ced2c4a
2017-03-16 14:14:44 -07:00
Fan Zhang
cabc509e4f Allow page to suppress all of its content from search.
To suppress things from search, we usually use preferencecontroller to
control individual items. But a page can sometimes to disabled
entirely. Now it can set isPageSearchEnabled to false to achieve that.

Change-Id: I39424b7fdc6460e27fd7c83cf09b5ace12d1cc37
Fix: 36201167
Test: make RunSettingsRoboTests
2017-03-14 13:59:33 -07:00