Fix UI flicker problem and update wordings

- "Set time zone automatically" changes to "Set automatically".
- "Use location to set time zone" changes to "Use location"
- Add a new summary text with "Location may be used to set time zone".

Fixes: 233968737
Test: make RunSettingsRoboTests -j ROBOTEST_FILTER=com.android.settings.datetime
Change-Id: Ia16c428e906cda4ebe052bad83c3f574075a7a64
This commit is contained in:
Sunny Shao
2022-06-16 16:10:02 +08:00
parent 50e4577787
commit d46dff8d4f
4 changed files with 7 additions and 5 deletions

View File

@@ -174,7 +174,7 @@ public class LocationTimeZoneDetectionPreferenceController
// If capability is possessed, toggle status already tells all the information needed.
// Returning null will make previous text stick on toggling.
// See AbstractPreferenceController#refreshSummary.
return "";
summaryResId = R.string.location_time_zone_detection_auto_is_on;
} else {
// This is unexpected: getAvailabilityStatus() should ensure that the UI element isn't
// even shown for known cases, or the capability is unknown.