Commit Graph

3640 Commits

Author SHA1 Message Date
jackqdyulei
99a2de41ef Add restrict and unrestrict dialog
Add a fake unrestrict tip so we could reuse the BatteryTipDialogFragment
to build the unrestrict dialog.

After this cl, restrict dialog has two types:
1. dialog to only restrict one app
2. dialog to restrict more than one app

Will add dialog to restrict more than 5 apps when strings are finalized.

Bug: 72385333
Bug: 72227981
Test: RunSettingsRoboTests
Change-Id: Ib0328f0386efad525b331fd713dd15d060a1a649
2018-02-05 19:37:03 -08:00
jackqdyulei
ab0cde6bad Add app restrict tip and detector
1. Add RestrictAppTip with two state(new and handled)
2. Add RestrictAppDetector, and future cl will hook up
it with anomaly database
3. Add related dialog in BatteryTipDialogFragment

Bug: 72385333
Test: RunSettingsRoboTests
Change-Id: Ic10efc6387150e62b6c6ad8d4c0d16ff75564fac
2018-02-05 19:34:48 -08:00
TreeHugger Robot
36952523bb Merge "Update suggestion UI" 2018-02-02 21:23:24 +00:00
TreeHugger Robot
4d869f2859 Merge "Support GLIF v3 for lock screen settings" 2018-02-02 20:12:43 +00:00
TreeHugger Robot
1297029728 Merge "Always show wifi wake setting." 2018-02-02 19:44:23 +00:00
Doris Ling
7fa083ece9 Update suggestion UI
- reduce space above and below the suggestion header
- reduce space around the suggestion cardview
- set the font family for the suggestion header and title.

Change-Id: Ief6247005f1e69fe5025af60f3c9627d357d94a4
Fixes: 72710227
Test: visual
2018-02-02 11:34:03 -08:00
TreeHugger Robot
d1afc3e42e Merge "Add ability to show/hide different device information." 2018-02-02 18:41:39 +00:00
yuemingw
a1416d2849 Rename DISALLOW_CONFIG_LOCATION_MODE to DISALLOW_CONFIG_LOCATION.
Bug: 72732481
Test: CtsVerifier test already in
Change-Id: I12a0593eba270727808588efc4c42c4e066c9446
2018-02-02 16:48:15 +00:00
TreeHugger Robot
7262d37c53 Merge "Highlight row (instead of ripple) when come from search." 2018-02-02 01:15:36 +00:00
TreeHugger Robot
abf3b8ad88 Merge "Fixes crash from selecting uninstalled app info from recents." 2018-02-02 00:35:42 +00:00
Joe LaPenna
3810036691 Always show wifi wake setting.
Remove WIFI_WAKEUP_AVAILABLE config setting its available by default.
Remove check for NETWORK_RECOMMENDATIONS_ENABLED, the feature no longer
uses the recommender.

Test: make RunSettingsRoboTests RunSettingsLibRoboTests;
Test: atest SettingsBackupTest; manual/exploratory
Bug: 69624403
Bug: 67952636
Change-Id: Ia65f7f9349e77a13ad4af1dbd992b28a5cb16368
2018-02-01 16:08:55 -08:00
Doris Ling
e679e9b1b4 Fixes crash from selecting uninstalled app info from recents.
- when the package is uninstalled, also remove it from the recent tasks
- move retrieveAppEntry() from onCreate() to getPreferenceControllers()
so that if the package info is invalid, do not create any controllers,
as the activity will be finished anyway.

Change-Id: Ibbfa16e3d1f941a0a200e78ec73a06ca8511f82b
Fixes: 72656345
Test: make RunSettingsRoboTests
2018-02-01 14:37:25 -08:00
TreeHugger Robot
a03335e0b9 Merge "Hide "Phone number" from About page if not call enabled." 2018-02-01 21:08:51 +00:00
Fan Zhang
3d516e7607 Highlight row (instead of ripple) when come from search.
- Moved HighlightableAdapter to its own class
- Replaced ripple with blue background
- Bluebackground only stays for 5 seconds. After that it's replaced by
  ?attr/selectableBackground

Misc fixes.

- Fix NPE in UserSettings
- Update char limit on a new string

Change-Id: I4687e54e71fd7b9243f520b7630563df58be23d4
Fixes: 71715698
Fixes: 72761974
Test: robotests
2018-02-01 12:35:25 -08:00
TreeHugger Robot
b67375876c Merge "Enforce disallow switch user in user settings" 2018-02-01 19:47:44 +00:00
TreeHugger Robot
0186c9d223 Merge "Check icon tintable flag of the Suggestion." 2018-02-01 19:12:35 +00:00
Alex Chau
ffae4c1a0e Enforce disallow switch user in user settings
Disallow the following actions which result in switch user when DISALLOW_USER_SWITCH is set
- Creating guest
- Showing user setup dialog for newly created user
- Clicking uninitialized user preference

Bug: 71694430
Test: CTSVerifier DeviceOwnerPositiveTest - DISALLOW_USER_SWITCH
Test: m -j ROBOTEST_FILTER=UserCapabilitiesTest RunSettingsRoboTests
Test: m -j ROBOTEST_FILTER=AddUserWhenLockedPreferenceController RunSettingsRoboTests
Test: m -j ROBOTEST_FILTER=UserSettingsTest RunSettingsRoboTests
Change-Id: Ia4c7e7b4947bfaf2ebeef4d32a473bdac542d6a6
2018-02-01 17:49:41 +00:00
Doris Ling
0e96107ddc Check icon tintable flag of the Suggestion.
- instead of checking the icon resource package, check the icon tintable
flag to see if we should tint the suggestion icon.

Bug: 72330968
Test: make RunSettingsRoboTests
Change-Id: I4767df05bebf815774dbd8e528c7ac0f5b902d44
2018-01-31 16:55:10 -08:00
Jerry Zhang
240f8c14bf Merge "Add new USB details screen for Connected Devices 2.0" 2018-01-31 23:41:32 +00:00
TreeHugger Robot
644bea8e0e Merge "Use SystemUpdateManager to provide system update info." 2018-01-31 22:05:21 +00:00
TreeHugger Robot
b832f737c3 Merge "Remove suggestion UI v1 codes." 2018-01-31 21:15:18 +00:00
Fan Zhang
74731f9fa6 Merge "Misc fixes for account/users fragments" 2018-01-31 21:13:31 +00:00
Fan Zhang
5c2699962b Use SystemUpdateManager to provide system update info.
Change-Id: I38b631cda8aa63e478c74625eba3d18f9a5723bd
Fixes: 36874007
Test: robotests
2018-01-31 12:16:17 -08:00
TreeHugger Robot
295a55b2fd Merge "AR/FR: Keyboard challenge takes precedence." 2018-01-31 19:42:03 +00:00
Jerry Zhang
d18d6f1022 Add new USB details screen for Connected Devices 2.0
Also updated UsbBackend to use the new UsbFunctions
api.

Added new unit tests for UsbDetailsHeaderController
and UsbDetailsProfilesController.

Bug: 69333961
Test: make RunSettingsRoboTests
Change-Id: I133750190bb61dfe0e20b06f50e50ea13b347f1e
2018-01-31 11:23:08 -08:00
Doris Ling
a5d0c3e36e Remove suggestion UI v1 codes.
- remove the check for feature flag for suggestion UI v2 and switch to
use the v2 codes.
- remove all code related to v1 of suggestion UI

Fixes: 70573674
Test: make RunSettingsRoboTests

Change-Id: I99ab318c1c0192508a9c5e9e708e86319120d55b
2018-01-31 10:59:40 -08:00
Fan Zhang
dc2a3528d5 Misc fixes for account/users fragments
- Hide add user button when it's not functional
- Display "No accounts added" under accounts setting when there is no account.

Change-Id: Iefede9939d206eb3064fa22bdcfbcb1e826f29ab
Fixes: 72643060
Test: robotest
Test: 72713118
2018-01-31 10:55:40 -08:00
Julia Reynolds
07c2cdee1f Merge "Notification settings updates" 2018-01-31 17:09:51 +00:00
Maurice Lam
f5b42777c1 Support GLIF v3 for lock screen settings
Also removed setup_divider_color because it's unused and is causing
a lint error.

Test: cd tests/robotests && mma
Bug: 72702989
Change-Id: I81894be6458439f688c0144d1136d3d7f75afa25
2018-01-30 21:01:42 -08:00
Carlos Valdivia
4b34dad4cd AR/FR: Keyboard challenge takes precedence.
Tested manually by:
(1) Setting up a gmail account.
(2) Setting up a screen pattern.
(3) Going to Settings > System > Reset Options > Factory Wipe
(4) Hit the Erase button.
(5) Enter pattern into the Screenlock prompt.
(6) Notice the Google credential confirmation screen.

Prior to this change we would skip (5) if there was a Google account on
the device.

Test: make RunSettingsRoboTests ROBOTEST_FILTER=andorid.settings.MasterClear
Bug: 72694056

Change-Id: Ie07c678ecbc8361e8e1792f82efdfb1261db49fb
2018-01-30 18:39:45 -08:00
TreeHugger Robot
ac1fc5c9b7 Merge "Re-add isSuggestionEnabled check" 2018-01-31 01:11:52 +00:00
Ben Lin
7190f85392 Add ability to show/hide different device information.
This introduces 3 boolean flags:

config_show_device_model
config_show_wifi_ip_address
config_show_wifi_mac_address

Which when set to false will hide their individual panes from "About
Phone" page.

Bug: 62414913
Test: make RunSettingsRoboTests
ROBOTEST_FILTER=com.android.settings.deviceinfo
Change-Id: Iaaf91ef41c9ec7b5bf233344e6a48d4b87fad291
2018-01-30 16:53:57 -08:00
Ben Lin
9703a9757a Hide "Phone number" from About page if not call enabled.
Bug: None
Test: make RunSettingsRoboTests
ROBOTEST_FILTER=com.android.settings.deviceinfo
Change-Id: Ib056bae12d23fe68e71fe78c92741b8dc7887de0
2018-01-30 16:04:11 -08:00
Fan Zhang
0ec6b02fe4 Re-add isSuggestionEnabled check
It was accidentally removed previously

Test: robotest
Change-Id: I5b7707e746d6b825d835a007727b29c9a81a7fc1
2018-01-30 15:41:33 -08:00
Julia Reynolds
4f3b556388 Notification settings updates
- Footer preferences were too dim
- Fix text and target on recently sent apps
- Make 'behavior' a dialog
- reorder settings on apps page

Change-Id: Idf8056bc77ead89fe2025bbde3346861e23a3c8d
Fixes: 72652526
Fixes: 72651810
Fixes: 72652024
Bug: 72651953
Test: make RunSettingsRoboTests
2018-01-30 16:59:12 -05:00
TreeHugger Robot
3b04494ac6 Merge "Change automatic brightness summary to absolute brightness." 2018-01-30 21:39:16 +00:00
TreeHugger Robot
5dda7faac0 Merge "Remove app info page v1 related codes." 2018-01-30 19:57:48 +00:00
TreeHugger Robot
85fd529cc4 Merge "Remve menu item in battery settings" 2018-01-30 19:04:26 +00:00
TreeHugger Robot
acd313e644 Merge "Move force stop button into option menu." 2018-01-30 06:30:20 +00:00
TreeHugger Robot
0be5e81526 Merge "Update suggestion card UI." 2018-01-30 03:55:28 +00:00
TreeHugger Robot
d3ee4e260d Merge "Dismiss suggestion when close button is clicked." 2018-01-30 01:26:23 +00:00
Doris Ling
ce55d7c6a1 Remove app info page v1 related codes.
- change to use AppInfoDashboardFragment completely
- remove InstalledAppDetails and the corresponding tests

Change-Id: I8cbdf71cadc8b5743929abbafe91185e5e39b6b2
Fixes: 69384089
Test: make RunSettingsRoboTests
2018-01-29 17:14:32 -08:00
Doris Ling
c04163a76e Update suggestion card UI.
- adjust suggestion card width and padding
- tint icon if it is from settings package.

Bug: 72330968
Test: visual
Change-Id: I4b82d51b3013ad0656d297305e0000958b71e94d
2018-01-29 16:39:31 -08:00
Doris Ling
604a3d2248 Move force stop button into option menu.
- only show 1 button in the app info page
- move all handling for the force stop button from
AppActionButtonPreferenceController to a new option menu controller

Bug: 71778950
Test: make RunSettingsRoboTests
Change-Id: Iaa2c9784162a5f1acaaf9e11e3ce988945b40538
2018-01-29 15:44:23 -08:00
TreeHugger Robot
75c2ca96f1 Merge "Remove security settings v1 code" 2018-01-29 23:25:09 +00:00
Sudheer Shanka
67ddb0ae00 Merge "Add policy transparency for metered data related settings." 2018-01-29 22:01:35 +00:00
Doris Ling
0e32252111 Dismiss suggestion when close button is clicked.
- add handling to the suggestion card to dismiss the suggestion when
the close button is clicked.

Bug: 70573674
Test: make RunSettingsRoboTests
Change-Id: I8155efc326242abde753a633009e2579a9b3aa9b
2018-01-29 13:20:32 -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
Michael Wright
30b66159aa Change automatic brightness summary to absolute brightness.
The brightness slider now always represents the absolute brightness,
including when adaptive brightness is enabled. This changes the summary
of the brightness setting to reflect that.

Bug: 72627086
Test: ROBOTEST_FILTER=BrightnessLevelPreferenceControllerTest m -j RunSettingsRoboTests
Change-Id: I76eed8aa9ee88fe6b70e30d54bfc0d18d1141377
2018-01-29 16:52:47 +00:00
TreeHugger Robot
9024b4eb15 Merge "Display a list of account types as account setting summary" 2018-01-28 21:16:17 +00:00