Commit Graph

10807 Commits

Author SHA1 Message Date
Yi Jiang
f68e8e32ec Merge "Hides Screen Attention setting on unsupported devices" 2020-10-30 03:45:34 +00:00
Yi Jiang
a56be2d614 Hides Screen Attention setting on unsupported devices
Bug: 170971817
Test: make RunSettingsRoboTests
Change-Id: I8aa7882be9a1ae483e8e7500059a18859b20d42b
2020-10-29 13:16:48 -07:00
Fan Zhang
005b47249e Merge "Rename panic gesture to emergency gesture in Settings" 2020-10-28 17:02:21 +00:00
Neil Fuller
be3b9ffeaa Merge "Fix review comments location_time_zone_detection" 2020-10-28 09:38:33 +00:00
Neil Fuller
1affbfff83 Fix review comments location_time_zone_detection
Fix review comments for location_time_zone_detection.xml and associated
classes from http://ag/12792958.

Bug: 152746236
Test: Manual: build / boot / toggle switch in SettingsUI / inspect output of adb shell dumpsys time_zone_detector
Test: Manual: build / boot / install TestDPC / toggle switch in work profile in SettingsUI / inspect output of adb shell dumpsys time_zone_detector
Test: m -j30 RunSettingsRoboTests ROBOTEST_FILTER="com.android.settings.location.TimeZoneDetectionPreferenceControllerTest"
Test: m -j30 RunSettingsRoboTests ROBOTEST_FILTER="com.android.settings.location.LocationTimeZoneDetectionPreferenceControllerTest"
Test: m -j30 RunSettingsRoboTests ROBOTEST_FILTER="com.android.settings.location.TimeZoneDetectionSettingsTest"
Change-Id: I641f312cd63359f45664a93e009e5a975dbd6485
2020-10-27 20:34:15 +00:00
Fan Zhang
f797a48af6 Rename panic gesture to emergency gesture in Settings
Bug: 171589858
Test: rebuild
Change-Id: I23847db82a397bdcd61501758e3ef66a4f088e22
2020-10-27 12:46:41 -07:00
TreeHugger Robot
167362d0ca Merge "Rename panic button in framework settings." 2020-10-26 20:27:50 +00:00
TreeHugger Robot
76c9a32dbb Merge "Update related UI if battery is not present" 2020-10-26 04:53:49 +00:00
Fan Zhang
6fef72aae4 Rename panic button in framework settings.
Renamed panic to "emergency" or "emergency gesture" to
avoid speculation once source code is accessible to
parties without full context.

The settings string and file names still use the word "panic". This
will be updated in a follow-up CL

Bug: 169946710
Test: rebuild
Change-Id: Ic1a3181145ca2b64ab6ef2a2989224395fa9a6f8
2020-10-23 22:51:01 +00:00
Mill Chen
ad99e2ef38 Update related UI if battery is not present
This change is to update the related UI in the battery page if the
battery is not present. This includes the following updates:
1. Update the summary of battery tile in the Settings homepage
2. Replace the battery level with "Unknown"
3. Replace the summary with help message in the battery page
4. Remove the battery meter icon

Bug: 171368508
Test: verify on an issue device
Change-Id: I892e0d137143160a0bce0c11ce9265120ebb8fd4
2020-10-23 23:35:15 +08:00
Julia Reynolds
5ff16e18e2 Merge "Add 'Recent Conversations' to the conversation page" 2020-10-23 14:35:46 +00:00
Neil Fuller
c91bcbd0d5 Merge "Changes to location settings for geotz" 2020-10-23 09:40:45 +00:00
Neil Fuller
f418b7a968 Merge changes I868d1912,Id483ca41
* changes:
  Fix search test using location_settings
  Revert "Stop search tests using location_settings"
2020-10-23 09:24:43 +00:00
Sally Yuen
4bca97c3cc Merge changes from topic "a11y_rbc"
* changes:
  Add activity for directly navigating to Reduce Bright Colors setting page
  Add a setting page for Reduce Bright Colors under A11y
2020-10-22 18:20:25 +00:00
Neil Fuller
4a6663c10a Changes to location settings for geotz
This change adds a new entry for geolocation-based time zone detection
(shorthand: "geotz") to the location settings.

The UI code uses information retrieved via the TimeManager API to keep
the conditional logic in one place, i.e. to avoid the UI needing to know
too much about the various conditions that affect the availability /
applicability of the toggle.

Screen variations / conditions / other info:

Location settings screen:

1) The entry only shows up on a device at all if geotz detection is
enabled for the device (currently a compile time setting, off by
default).
2) The new entry is hidden on the screen when the user first opens it.
To see it, the user has to expand "Advanced". The setting is in the
shared (non-GMS) section of the screen.
3) When visible, the entry has a summary that shows the current status:
either a reason why the setting is not applicable, or the user's current
setting value.
4) Selecting the entry opens a sub-screen.

The code included here distinguishes between different cases with the
summary message (i.e. the text underneath the entry). See strings.xml
for the placeholder text. Some strings will not show up currently, but
are included in case the rules change as they are valid possibilities
from the TimeManager API.

The same changes have been made for the "personal" tab when a work
profile is enabled.

Location Time Zone Detection settings screen:

1) The toggle is always enabled and always shows the user's current
configuration setting.

All manual tests run with the geotz feature enabled with:

adb shell setprop \
    persist.sys.location_time_zone_detection_feature_enabled 1

Bug: 152746236
Test: Manual: build / boot / toggle switch in SettingsUI / inspect output of adb shell dumpsys time_zone_detector
Test: Manual: build / boot / install TestDPC / toggle switch in work profile in SettingsUI / inspect output of adb shell dumpsys time_zone_detector
Test: m -j30 RunSettingsRoboTests ROBOTEST_FILTER="com.android.settings.location.TimeZoneDetectionPreferenceControllerTest"
Test: m -j30 RunSettingsRoboTests ROBOTEST_FILTER="com.android.settings.location.LocationTimeZoneDetectionPreferenceControllerTest"
Test: m -j30 RunSettingsRoboTests ROBOTEST_FILTER="com.android.settings.location.TimeZoneDetectionSettingsTest"
Change-Id: Ia853d30bc54a113000b30f48776418f262d98358
2020-10-22 15:48:55 +01:00
Neil Fuller
94a64d6139 Fix search test using location_settings
Second attempt to proactively fix a search test.

SearchIndexableResourcesTest uses the FakeIndexProvider, which
implicitly assumes that the
robotests/res/xml-mcc999/location_settings.xml xml is in use. Without
it, the test is accessing the real location_settings.xml / real
preference controllers. This  was working until now, but by luck and
probably not intent.

There is an upcoming change which will break the test, so this fixes the
test ahead of time.

This change updates the test to use the "mcc999" config, and improves
the docs around FakeIndexProvider to try to make the requirements for
use clearer.

Bug: 171371424
Test: m RunSettingsRoboTests
Change-Id: I868d191281a2030fa49134893bcd6720f757ea91
2020-10-22 15:46:39 +01:00
Neil Fuller
d11f93babe Revert "Stop search tests using location_settings"
This reverts commit b71f7af512b506ee74f75f92a1cc254018c3c924.

Bug: 171371424
Test: m -j30 RunSettingsRoboTests
Change-Id: Id483ca41d3aced0893f0eff370270b5010eb8a7a
2020-10-22 15:38:23 +01:00
Sally
b9ff672a31 Add a setting page for Reduce Bright Colors under A11y
This is essentially a copy page of ToggleDaltonizerPreferenceFragment.
We extend ToggleFeaturePreferenceFragment to maintain consistency with
other shortcut assignable a11y feature.

UI is a draft

This CL:
1) allows users to enabled/disable RBC with the a11y shortcut (button,
gestures, volume keys), if assigned
2) adds a slider and persist switch to the template
ToggleFeaturePreferenceFragment page (which already contains a feature
switch, shortcut preference, and footer description)
3) enables/disables the intensity slider when RBC is on/off
4) sets placeholders for calling into ColorDisplayService in
controllers and tests
5) follows convention set by other color transformations settings and
places feature under Experimental section in A11y settings page if
transformations can't be efficiently performed by hardware

Test: A11y setting and page appears, tested activation with shortcut,
preference controller tests
Bug: b/128465252

Change-Id: I291bb86ce3d855ce052ca70dc7a941a888e2c723
2020-10-21 23:08:53 +00:00
Julia Reynolds
0aef57d67e Add 'Recent Conversations' to the conversation page
Test: atest
Bug: 171191376
Change-Id: Id7208312dff0cc022c2f16b3872fae1a9dc09ed7
2020-10-21 16:39:04 -04:00
Neil Fuller
c79680cbae Merge "Stop search tests using location_settings" 2020-10-21 11:21:29 +00:00
Neil Fuller
c970f4d79c Stop search tests using location_settings
Stop robolectric search tests using location_settings, use
sound_settings instead.

The choice of location_settings.xml seems arbitrary, and there's a
commit coming which means one of the controllers doesn't just use
settings to check availability. When the unconfigured mock returns null
from a method, that causes the test to fail in a non-obvious way.

Bug: 171371424
Test: m RunSettingsRoboTests
Change-Id: I4d3386e3c62fb4151e4a4e27625edccec89316d9
2020-10-21 09:25:57 +00:00
Bonian Chen
d682b2cc57 Merge "[Settings] Only display 1 SIM UI when multiple with same group UUID" 2020-10-21 08:37:37 +00:00
SongFerng Wang
c023d49669 Merge "To fix bug, summary is wrong if nr_enabled_bool=false" into rvc-qpr-dev am: 3e5defe561 am: 9493731935
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/12875667

Change-Id: I3b06b785b0ae6d907f7cd6f09d7830c5b8cdb0c3
2020-10-21 08:36:22 +00:00
SongFerng Wang
9493731935 Merge "To fix bug, summary is wrong if nr_enabled_bool=false" into rvc-qpr-dev am: 3e5defe561
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/12875667

Change-Id: I2b69a34d035e70cbc1bea9a2482be876eeabda66
2020-10-21 08:19:13 +00:00
Bonian Chen
a6b249d625 [Settings] Only display 1 SIM UI when multiple with same group UUID
Some carrier(s) expand their service through providing eSIM in companion
with pSIM. Group UUID is designed to group them together as an single
SIM.

Bug: 165363542
Test: make RunSettingsRoboTests ROBOTEST_FILTER=SubscriptionsPreferenceControllerTest
Change-Id: I0934a45a2917ab106627c733162efbee9a13f216
2020-10-21 13:31:04 +08:00
Yanting Yang
3f92484ce8 Merge "Remove subtitles for the homepage IA" 2020-10-21 03:24:31 +00:00
Weng Su
3a45d054eb Fix the Wi-Fi detailed settings un-editable issue.
- The WifiEntry info might not be ready in early stage. (ex:
WifiEntry#canSetPrivacy())

- The Wi-Fi detailed setting listens to the WifiEntry callback to
refresh the preferences, it should first update the preference status to
be editable or not, and then display preferences to the UI.

- The privicy preference should be able to set back to selectable when
WifiEntry#canSetPrivicy() change from false to true.

Bug: 170148009
Test:
make RunSettingsRoboTests
ROBOTEST_FILTER=WifiNetworkDetailsFragment2Test
make RunSettingsRoboTests
ROBOTEST_FILTER=WifiPrivacyPreferenceController2Test

Change-Id: I567b2b80163631a01d165c0ac5c0aba392e014ef
2020-10-21 04:30:09 +08:00
Yanting Yang
9aa4a5463f Remove subtitles for the homepage IA
Remove the summary of the homepage IA if silky home enabled.

Fixes: 170933968
Test: robotest & visual with turning on/off silky home
Change-Id: I502b6590cece9b80e9923109fe0582cc4d9a1c56
2020-10-20 23:54:03 +08:00
SongFerngWang
706036e5b3 To fix bug, summary is wrong if nr_enabled_bool=false
The carrier config nr_enabled_bool is false, preferred network mode
should hide 5G UI. This bug is that the summary show 5G item when
nr_enabled_bool is false.
Solution: if nr_enabled_bool is false, it checks capability and then
removes 5G capability of network mode.

Bug: 170460943
Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
EnabledNetworkModePreferenceControllerTest   (PASS)
Change-Id: I3f7d41c196569c0cb61e89cfc270b957e2f0add5
2020-10-20 13:07:59 +00:00
TreeHugger Robot
886fe1e6ab Merge "Revert "Modify the privacy controller to be selectable in the next updateState()"" 2020-10-20 03:20:36 +00:00
Weng Su
67f95bfd2f Revert "Modify the privacy controller to be selectable in the next updateState()"
This reverts commit f71149911b.

Reason for revert: Some unexpected code mixed in this CL.

Change-Id: I43574314554a9c62559f529e45f69c29ba6b5a77
2020-10-20 02:12:28 +00:00
Andrei-Valentin Onea
786d3578d1 Merge "Add support for @EnabledSince compat changes" am: 2d57867aba am: 38747f76f3 am: 8e111e3de3 am: acfad23908
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1455019

Change-Id: I2eef4a833d3305a13aad13477fb46cf40ecd3068
2020-10-19 15:53:58 +00:00
Andrei-Valentin Onea
acfad23908 Merge "Add support for @EnabledSince compat changes" am: 2d57867aba am: 38747f76f3 am: 8e111e3de3
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1455019

Change-Id: Iec4b14d29945ae3088838428cc48b36ae71faeb2
2020-10-19 15:26:01 +00:00
Andrei-Valentin Onea
8e111e3de3 Merge "Add support for @EnabledSince compat changes" am: 2d57867aba am: 38747f76f3
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1455019

Change-Id: I60df429605c78749c0259f7efffab026210a4977
2020-10-19 14:56:40 +00:00
Jason Chiu
2d047a1e2f Merge "[Injection] Refine UI behavior for icon_uri" 2020-10-19 14:50:20 +00:00
Andrei-Valentin Onea
38747f76f3 Merge "Add support for @EnabledSince compat changes" am: 2d57867aba
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1455019

Change-Id: I600c63a996b1684a2b801787d88974501062c073
2020-10-19 14:37:30 +00:00
Andrei-Valentin Onea
2d57867aba Merge "Add support for @EnabledSince compat changes" 2020-10-19 14:19:31 +00:00
Weng Su
2e49b2e639 Merge "Modify the privacy controller to be selectable in the next updateState()" 2020-10-19 09:51:23 +00:00
Jason Chiu
fb36be1a2f [Injection] Refine UI behavior for icon_uri
1. Make the icon provided by the content provider override static icon.
2. Apply the background settings "bg.hint" and "bg.argb" to icon_uri.

Bug: 167568758
Test: visual, robotest
Change-Id: I44c66d8ea2686df1dfe1f9ad28645da7e21414ed
2020-10-19 15:25:58 +08:00
Weng Su
f71149911b Modify the privacy controller to be selectable in the next updateState()
Listen WifiEntry#onUpdated() to update preference states will be modify
in next CLs.

Bug: 170148009
Test: make RunSettingsRoboTests ROBOTEST_FILTER=WifiPrivacyPreferenceController2Test
Change-Id: I5acf096970431a0b093dd7e0968f30c1959e3b7f
2020-10-19 14:37:03 +08:00
TreeHugger Robot
ccccc79043 Merge "Fix output switcher will show 2 media session in some use cases" 2020-10-19 04:12:50 +00:00
TreeHugger Robot
9c989442d1 Merge "Hide 'View plan' button in data usage settings" into rvc-qpr-dev am: 1a09d244d4 am: 09a906b972
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/12755868

Change-Id: I8101838915bb821e9ce6483ba2c7d21ad894a0e5
2020-10-16 22:58:21 +00:00
TreeHugger Robot
09a906b972 Merge "Hide 'View plan' button in data usage settings" into rvc-qpr-dev am: 1a09d244d4
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/12755868

Change-Id: I0026c3fbb1bf26d68f203c36c49576deb6d79681
2020-10-16 22:42:07 +00:00
Hugh Chen
3a7293cbbf Fix output switcher will show 2 media session in some use cases
Before this CL, we didn't check whether the remote session existed
in the list before. If priority of remote session is higher than
local session, it causes us to return the local session even if
the list has a remote session.

This CL uses a list to cache package names of remote sessions.
If the local session has the same package name of the remote session
then don't return the local session.

Bug: 169052790
Test: make -j42 RunSettingsRoboTests
Change-Id: I2726a3deb397f646e4c74a8c445dde6fafb694a8
2020-10-16 16:08:48 +08:00
TreeHugger Robot
0e7d09fc8c Merge "Launch customized panic setting intent when configured." 2020-10-15 00:09:53 +00:00
Fan Zhang
c63a13c858 Launch customized panic setting intent when configured.
When RRO provides a custom intent package for panic settings and there
is an app to handle it, launch the custom intent instead of the AOSP
version.

Bug: 169946508
Test: robotests
Change-Id: I8479c6e0dd4a90b5a03640035b710ae4ccc7809c
2020-10-14 12:20:33 -07:00
Sally Yuen
80c5b8ffe3 Merge "Add Bold Text to Accessibility settings screen" 2020-10-14 16:08:13 +00:00
Hugh Chen
e16a8077b5 Fix output switcher will show 2 media session when remote playing
Before this CL, output switcher will show 2 media sessions when
some apps are remote playing. The root cause is some apps will
also create local media sessions when they cast media to remote
playing.

This CL add condition to only show remote sessions on output switcher
if apps both have remote and local sessions.

Bug: 169052790
Test: make -j42 RunSettingsRoboTests
Change-Id: I80479d35b2bb2e353cf41f41f457f2dfd15cadbf
2020-10-14 17:58:47 +08:00
Yi Jiang
79dc82fb6f Merge "Merge Screen Attention and Screen timeout Settings." 2020-10-14 05:07:40 +00:00
TreeHugger Robot
2228c642b8 Merge "Fix crash on "Connection preferences"" 2020-10-14 03:36:43 +00:00