Commit Graph

8408 Commits

Author SHA1 Message Date
Yanting Yang
4e56cb2917 Add a way to suppress injected tiles for OEMs
Create a config resource for OEMs to add suppressed tile's key, then
DashboardFragment will filter related tiles out from Settings.

OEMs can use this way to suppress security patch injected tile if they
don't use Google OTA.

Fixes: 130734771
Test: visual, robotests
Change-Id: I4cab79c8672048fa543d39b2a8f38ffe338189c8
2019-04-20 01:31:07 +08:00
Linda Tseng
ae344faf4a Merge "Set max num of slices allowed in panel view" into qt-dev 2019-04-19 17:19:59 +00:00
TreeHugger Robot
1115d61c0b Merge "Fix broken tests" into qt-dev 2019-04-19 16:32:15 +00:00
TreeHugger Robot
e69a25caad Merge "Remove all device from preference when BT is disabled" into qt-dev 2019-04-19 16:25:26 +00:00
Julia Reynolds
9c5a19319b Fix broken tests
Test: robo tests
Fixes: 130871450
Change-Id: If7b01147f5680392c7635f3a3b4e558aa56a633e
2019-04-19 10:03:40 -04:00
Stanley Wang
7f46c8714e Merge "Hardware version should should support copy action" into qt-dev 2019-04-19 07:35:46 +00:00
hughchen
ef2c1a1526 Fix crash when no Bluetooth feature in Settings
- Move PreferenceGroup init method out of isAvailable() condition,
  then PreferenceGroup will not be null.
- Update getAvailabilityStatus(), since the controller now may have usb
  and dock.

Bug: 110712414
Test: make -j42 RunSettingsRoboTests
Change-Id: I4d85a42c26fb20d319e7321177b271933be3fdb0
2019-04-19 14:09:40 +08:00
TreeHugger Robot
6e2fce6fdc Merge "Don't show policy transparency UI for cross-profile setting." into qt-dev 2019-04-19 05:24:24 +00:00
Stanley Wang
0fdf78cff6 Hardware version should should support copy action
Implement isSliceable method in HardwareRevisionPreferenceController

Fixes: 130653205
Test: manual and robotests
Change-Id: Ib872b9625c2c1984ff7b036fef5b3145c7fd8d2a
2019-04-19 11:52:32 +08:00
hughchen
d39fbe0f23 Remove all device from preference when BT is disabled
The issue is happened when BT is disabled then navigate to
"Connected devices". BluetoothDeviceUpdater didn't update
UI when BT is disabled. Remove all device from preference when
BT is disabled.

Bug: 80090956
Test: make -j42 RunSettingsRoboTests
Change-Id: Ia1fd8cfbcf95d712a1a702fdf101ff98186b76cd
2019-04-19 09:50:03 +08:00
Cn Chen
9588c9003f Merge "Update fingerprint suggestion enable state when back pressed" into qt-dev 2019-04-19 01:37:13 +00:00
TreeHugger Robot
8bfc277f7d Merge "Non-blockable whitelist should only control importance fields" into qt-dev 2019-04-18 21:56:02 +00:00
Mill Chen
d0dd6d8885 Merge "Revert "Add robotest modules for Settings"" into qt-dev 2019-04-18 21:49:51 +00:00
Mill Chen
db9f07850f Revert "Add robotest modules for Settings"
This reverts commit ce09f58360.

Reason for revert: will build break on run_host_tests

Bug: 130774632

Change-Id: Id2ee52ffb0689059da9cbdadd5bdae5b6a04a589
2019-04-18 21:48:42 +00:00
Julia Reynolds
9496bce441 Merge "Redesign channel listing and channel page" into qt-dev 2019-04-18 21:34:36 +00:00
TreeHugger Robot
93aee0d99d Merge "Fix regression of wrong min value on night display slice" into qt-dev 2019-04-18 19:44:43 +00:00
Julia Reynolds
73c647513b Non-blockable whitelist should only control importance fields
Sounds, etc. should still be modifiable

Test: robotests
Fixes: 130086523
Change-Id: I1a95a73b299bb3afd169b249a3dabae3583a448a
2019-04-18 18:58:12 +00:00
Julia Reynolds
5c097c6d3c Redesign channel listing and channel page
Test: atest
Bug: 127796543
Fixes: 129452112
Fixes: 129453207
Change-Id: I1d520c9e35860303235b7ffbb18a76cbc4f4b8bc
2019-04-18 18:51:23 +00:00
TreeHugger Robot
670bf45b50 Merge "Add Settings keywords for Styles & Wallpaper." into qt-dev 2019-04-18 18:43:35 +00:00
Lei Yu
15899e8b0e Add SettingsPolicy to control BT feature
Fixes: 130302238
Test: RunSettingsRoboTests
Change-Id: I7e1bf55c476f8e4d3dec7a7dfc0e8d44e5bd53ae
2019-04-18 11:31:05 -07:00
TreeHugger Robot
95073738ea Merge "Move "Build Number" slice to a different controller." into qt-dev 2019-04-18 18:16:19 +00:00
lindatseng
55f66a9177 Fix regression of wrong min value on night display slice
The min value of NightDisplayIntensityPreferenceController
should always be 0 (which is the old value we used before
ag/7062353). The range is cacluated from the relative value
to MinimumColorTemperature, which means the min value should
always be 0.

Test: atest NightDisplayIntensityPreferenceControllerTest
Fixes:130758028
Change-Id: Ica75672dda6a9ee0c6013f1c903611263b7d133f
2019-04-18 11:11:12 -07:00
TreeHugger Robot
7f9a86d869 Merge "Prevent bad apps from getting Setting Slices" into qt-dev 2019-04-18 17:38:28 +00:00
Amin Shaikh
87ef55ea90 Add Settings keywords for Styles & Wallpaper.
Reusing existing strings since this is coming in after string freeze.
TODO: create a new keyword string for this preference.

Fixes: 130759285
Test: m RunSettingsRoboTests and searching keywords on device
Change-Id: Ice1bc34b381302745cb55056377cc94ea74e8d50
2019-04-18 13:29:15 -04:00
Fan Zhang
6dade8e430 Move "Build Number" slice to a different controller.
There are 2 build number tiles in settings: Android version -> Build
number and About phone -> build number.

The way we index breadcrumb for each slice is making some client
confused. So this change moves the slice capability from Androi
version>BuildNumber to About phone.

Fixes: 130652710
Test: reindex, robotest
Change-Id: I9054d0db124b706e7984cd3d19774bb604bd7fd3
2019-04-18 09:37:15 -07:00
Matthew Fritze
2bdea1d922 Prevent bad apps from getting Setting Slices
SettingsSliceProvider no longer allows apps to request permission
from the user for Settings Slices. Instead, the PrimaryAction on the
permission slice will be an intent into Settings.

This is because the dialog for granting apps Settings Slices would act
as a replacement for regular permission dialogs, which we want to avoid.

Fixes: 130795282
Test: robolectrico
Change-Id: I6848215bab2bf10ee5e53814b765d04f04f53f4e
2019-04-18 08:51:17 -07:00
markchien
8667e01cf5 Ignore the outdated entitlement check
Don't run entitlement if the request is base on outdated subId.

Bug: 129751453
Test: -build, flash, boot
      -atest TetherServiceTest
      -manual test with carrier SIM

Change-Id: Id3157df1a5758f8c72acbc45c9fefd2215c87395
Merged-In: Id3157df1a5758f8c72acbc45c9fefd2215c87395
2019-04-18 13:53:40 +00:00
Jonathan Scott
ed701572d7 Don't show policy transparency UI for cross-profile setting.
Also removes the switch if cross-profile calendar is disabled by admin.

Test: atest ManagedProfileSettingsTest
Fixes: 123930863
Change-Id: Ieeb9266e8833d7ca730fedb5e947b03ec7d18d3c
2019-04-18 11:31:50 +00:00
cnchen
706fbc172e Update fingerprint suggestion enable state when back pressed
Test: manual test && atest SetupFingerprintEnrollFinishTest
Bug: b/130666973
Change-Id: Ie6be2f6ce77f29c9f25743f92597b5f7297048a9
2019-04-18 09:44:28 +08:00
TreeHugger Robot
bb00e4c028 Merge "[PasspointV2] Set summary of saved networks preference" into qt-dev 2019-04-18 00:58:22 +00:00
TreeHugger Robot
f590d5c617 Merge "Implement context menu for ConnectedAccessPointPreference" into qt-dev 2019-04-18 00:33:41 +00:00
TreeHugger Robot
f6f4ae6e1c Merge "Remove on/off subtext from gesture preferencecontrollers" into qt-dev 2019-04-18 00:29:33 +00:00
Fan Zhang
57f18af554 Remove on/off subtext from gesture preferencecontrollers
The toggle switch next to the subtitle already shows on/off clearly.

Fixes: 130652619
Fixes: 130652843
Fixes: 130653459
Fixes: 130653297
Test: robo
Change-Id: Ib2396575bbc69a7cca5e9c90e113c76ff6db00b5
2019-04-17 23:49:25 +00:00
Mill Chen
0e38f902c5 Merge "Add robotest modules for Settings" into qt-dev 2019-04-17 23:42:52 +00:00
Mill Chen
ce09f58360 Add robotest modules for Settings
Use ROBOTEST_FILTER to divide RunSettingsRoboTests into several smaller
parts.

Bug: 130511490
Test: make -j RunSettingsRoboTests-applications && make -j
RunSettingsRoboTests-wifi

Change-Id: I16ea575877df7a495de9344971421d221e197b89
2019-04-17 16:37:16 -07:00
TreeHugger Robot
c82a225c6f Merge "Default to enable oem-unlocking preference" into qt-dev 2019-04-17 16:54:19 +00:00
cosmohsieh
e6e4b4d78d [PasspointV2] Set summary of saved networks preference
Summary text of "saved networks" preference has number of both normal
networks and subscriptions

Bug: 130259573
Test: make RunSettingsRoboTests -j32 ROBOTEST_FILTER=com.android.settings.wifi.WifiSettingsTest
Change-Id: I8bdf41c1a85165298a2ccd9e688c30b0bd593bfa
2019-04-17 18:21:09 +08:00
Clown SHEN
5466ef6da5 Merge "Retrieve WiFi detail test cases" into qt-dev 2019-04-17 02:48:24 +00:00
lindatseng
634d8b3ee4 Set max num of slices allowed in panel view
Setup a max allowed num for PanelSlicesAdapter to prevent too
many slices showing in single panel.

Test: Manual verify
Test: atest PanelSlicesAdapterTest
Fixes: 129358092
Change-Id: I7b72a29489e597b8309d74841eaeab0fe42aace6
2019-04-16 17:28:14 -07:00
TreeHugger Robot
e991b05b29 Merge "Check for attention permissions" into qt-dev 2019-04-16 22:02:43 +00:00
TreeHugger Robot
cef4e42dc2 Merge "Enforce min value on panel slices slider" into qt-dev 2019-04-16 21:18:05 +00:00
Lei Yu
ad06c36882 Merge "Hide Mobile preference for secondary user" into qt-dev 2019-04-16 20:47:17 +00:00
Linda Tseng
71df263db9 Merge "Add entry animation to Settings Panels." into qt-dev 2019-04-16 18:57:47 +00:00
TreeHugger Robot
421ca22a58 Merge "Disable Mobile settings in one condition." into qt-dev 2019-04-16 18:20:11 +00:00
TreeHugger Robot
3b8a0b82bf Merge "Change dark theme screen to toggle" into qt-dev 2019-04-16 18:16:54 +00:00
TreeHugger Robot
03c461b3ee Merge "Hide filter spinner when data is loading." into qt-dev 2019-04-16 18:07:24 +00:00
Alex Salo
c821ae1ee6 Check for attention permissions
If attention package does not have sufficient permissions - disable the
setting.

Bug: 130246574, 130350903
Test: make RunSettingsRoboTests and manually confirmed
Change-Id: Ia7a86c940522e72f7e895d6aec7500f1ef6f9889
2019-04-16 17:43:15 +00:00
clownshen
5e3261616f Retrieve WiFi detail test cases
1. fix test case failure
2. remove redundant test cases

Bug: 130640128
Test: make RunSettingsRoboTests -j32 ROBOTEST_FILTER=com.android.settings.wifi.details.WifiDetailPreferenceControllerTest
Change-Id: Ia59287d7f9adb37a6b56301a2178b6e307fd892d
2019-04-17 01:11:49 +08:00
lindatseng
fadedb321c Enforce min value on panel slices slider
We did not set the min value on slider slices when converting them
from preference to slices, which makes the slices all have min 0.
However, there are some slider which should have min value greater
than 0, for example, call and alarm.

We should get the min value and apply it to slider slice to make it
consistent with what we have in settings pref.

Test: Manual verification
Test: make -j40 RunSettingRobotests
Test: atest VolumeSeekBarPreferenceControllerTest
Fixes: 130439216
Fixes: 130358208
Change-Id: Ib4399c36c7da3ac41a6d46a6c150f0ec1b9b0b0f
2019-04-16 16:30:08 +00:00
Matthew Fritze
b6fdd25c23 Add entry animation to Settings Panels.
Settings Panels as a dialog have a default animation for entering the
screen, but Slices complicate the animation. While the dialog enters the
screen, Slices begin to bind, thus changing the height of the dialog as
it enters, causing perceived bounce / jank in the animation.

This CL is cherry-picked/based on ag/6671083 but do the following modification:
(See the original commit message for the whole concept)

When trying to load all the Slices, there are few possible situations:
1. Slice starts loading slowly, starting at state LOADED_NONE
2. Slice is loading in progress, having state LOADED_PARTIAL
3. Slice is loaded, but there's error return from the Slice data (We don't
need to show the Slice in this case)
4. Slice is loaded, progress to state LOADED_ALL
5. Slice starts from state LOADED_NONE, but never progress to the next state
because it crashes at setting backend.

Notice that there are two cases that the state will stay at LOADED_NONE and
we can't distinguish them.

Hence, we decide to do the following:

If Slice is with error (case 3) we remove the slice from the list and mark it
loaded.

If Slice is loaded with LOADED_ALL (case 4, which is the ideal case), we mark
it as loaded.

In the other cases, we fire a handler to mark the slice loaded anyway after
250ms timeout.

When all the slices are marked loaded (which should happen after 250ms timeout,
we will animate the panel out.  Although there might be slices which are still
partial loaded, we can still have the slice in the panel once it is ready.
The panel might bounce/jank in this case, but at least it will still showing
correctly, and should show up smoothly in most cases.

The solution to this problem is twofold:
1. Load all Slices first
2. Create a custom animation to draw the panel once the recyclerview has
been laid out.

Test: Manual/Visual inspection
Test: make -j40 RunSettingsRobotests
Bug: 123942159

Change-Id: I639a707aa4ba3f906bd6f9752c92727aaba28142
2019-04-16 16:29:04 +00:00