Commit Graph

60310 Commits

Author SHA1 Message Date
Tim Peng
40111a5988 Update "Play <APP> to" to "Play <APP> on"
-design changes

Bug: 155345595
Test: build pass
Change-Id: I860673d22c57477bd2505360f0034731b28c7208
2020-05-05 11:01:03 +08:00
Arc Wang
032f77052b Merge "[Wi-Fi] Modify NetworkRequestDialog title & summary" into rvc-dev 2020-05-05 01:02:05 +00:00
Marco Ballesio
cb96685c8f Developer option for the app freezer
The app freezer allows the system to suspend execution for cached apps.
Without it an app can receive CPU time even if cached, so this option
will allow developers to test their code when frozen while their apps
are cached.

The new developer option will present a list of alternatives for the
freezer operating mode:

"device default": use device/system settings to determine whether the
                  freezer is to be enabled or not. This is the current
                  behavior, and default value for the option.
"enabled": force freezer on
"disabled": force freezer off

A dialog prompting the user to reboot is presented upon freezer mode
change. The device is automatically rebooted if the user decides to
proceed.

Bug: 155465196
Change-Id: I857b77cc4fc1ad766e8d5825ada9b271d3e1ab3a
Test: manually verifued the option works as intendend when this patch is
applied with its companion CLs

Change-Id: I26450b7b7ea2b345fd3661d4869fbc74ae38c0c9
2020-05-04 11:29:10 -07:00
SongFerngWang
b7f98f7667 Remove the second network scan.
Fix: 153427564
Test: make RunSettingsRoboTests ROBOTEST_FILTER=NetworkSelectSettingsTest
(PASS)

Change-Id: If593fc4a4dd463bbc178b4864ad0ba01bb421b09
2020-05-04 22:31:15 +08:00
Julia Reynolds
9bb55e1084 Update some notification strings
Test: manual
Fixes: 155516603
Fixes: 155516894
Change-Id: I86058ebdb473890239236d30414cb05787832311
2020-05-04 10:25:57 -04:00
TreeHugger Robot
15254e3b5e Merge "Fix broken test cases" into rvc-dev 2020-05-04 11:12:50 +00:00
Bonian Chen
1ab100e936 Merge "[Settings] Code refactor" into rvc-dev 2020-05-04 10:41:47 +00:00
Bonian Chen
068eb89251 Merge "[Settings] Enable access from non-UI thread" into rvc-dev 2020-05-04 10:41:16 +00:00
Tsung-Mao Fang
17b882a94d Fix broken test cases
Since we added a new API in ag/11355641,
we need to shadow this new new API.

Fix: 130916962
Test: run robo test
Change-Id: I2176253aae915d1a31043ebbf197d4dd1b1f2072
2020-05-04 17:22:01 +08:00
Bonian Chen
07431066c4 Merge "[Settings] Code refactor for availability session" into rvc-dev 2020-05-04 08:49:21 +00:00
tim peng
1424b594c9 Merge "Modify rule of remote media session UI" into rvc-dev 2020-05-04 08:47:41 +00:00
Bonian Chen
7ea8e7ef1e [Settings] Code refactor for availability session
Code refactor for session design of availability status config.

Bug: 141833767
Test: manual
Change-Id: Ia4982bc4036abbcff5ee1a4bba69bdf6f70ad657
2020-05-04 14:35:23 +08:00
Bonian Chen
017cc4e48f [Settings] Crash avoidance
Avoid crash when NullPointer.

Bug: 155248992
Test: manual
Change-Id: I5e4b46dcdf7ff21713b3f77fc9e20f503800b8e2
2020-05-04 14:11:09 +08:00
Tim Peng
e9b91f08c4 Modify rule of remote media session UI
-Add preference by remote session in Sound Setting
-Add slice item by remote session in Volume panel
-Replace media device data with media session data
-Add test case

Bug: 154918214
Test: make -j50 RunSettingsRoboTests
Change-Id: Ib1c873c9f99eebcba377f4115c4b9b4297b20c3d
2020-05-04 12:21:20 +08:00
Lucas Dupin
7dc7252c15 Merge "Create QS media player setting" into rvc-dev 2020-05-04 03:59:28 +00:00
Bonian Chen
3d62032fed [Settings] Query historical data in background
Move the query of historical data into background thread to avoid from
blocking other query operation in UI thread,

Bug: 141833767
Test: make RunSettingsRoboTests -j ROBOTEST_FILTER=DataUsageSummaryPreferenceControllerTest
Test: make RunSettingsRoboTests -j ROBOTEST_FILTER=DataUsagePreferenceControllerTest
Change-Id: I61e414d70136a0025ddd7373a4f34a99acb89510
2020-05-04 11:57:44 +08:00
Bonian Chen
d231727e3b [Settings] Code refactor
Move some work out of constructor of
EnabledNetworkModePreferenceController.
Which could avoid callbacks before init() been invoked.

Bug: 141833767
Test: make RunSettingsRoboTests -j
ROBOTEST_FILTER=Enhanced4gBasePreferenceControllerTest
Test: make RunSettingsRoboTests -j ROBOTEST_FILTER=EnabledNetworkModePreferenceControllerTest
Change-Id: I11f25d130a746c75184a21a8991177b02ad237f0

Change-Id: I6aa58a8d9d15b1524bf03f425e3eae3a0254593e
2020-05-04 11:48:09 +08:00
Bonian Chen
2a7767ee26 [Settings] Adopt TelephonyBasePreferenceController
Adopt TelephonyBasePreferenceController for better support on multi-SIM
environment.

Bug: 143996139
Test: make RunSettingsRoboTests -j
ROBOTEST_FILTER=DefaultSubscriptionControllerTest
Test: make RunSettingsRoboTests -j
ROBOTEST_FILTER=DisableSimFooterPreferenceControllerTest

Change-Id: I8a9c6efa927be1cb4a7ab4ebe816dcad9f20bd70
2020-05-04 11:23:11 +08:00
Bonian Chen
19507e7585 [Settings] Enable access from non-UI thread
To support query from settings intelligent, these listeners need to
support accessing from non-UI thread.

Bug: 149543756
Test: make RunSettingsRoboTests -j ROBOTEST_FILTER=ActiveSubsciptionsListenerTest
Change-Id: I768f41f76d0223634be2b728d33fa0cfcc69fe69
2020-05-04 11:07:41 +08:00
Bonian Chen
a9de4477e6 [Settings] Avoid from crash
Avoid from crash when updateState() performed before
displayPreference().

Bug: 141833767
Test: make RunSettingsRoboTests -j
ROBOTEST_FILTER=ApnPreferenceControllerTest

Change-Id: I4008010077c61930487fef01af306ccdfd69e38f
2020-05-04 10:59:58 +08:00
Sunny Shao
6d60248053 Enable some settings pages to use paralleled-loading method
- Here these pages include AppInfoDashboardFragment, ConnectedDeviceDashboardFragment,
  DevelopmentSettingsDashboardFragment, NetworkDashboardFragment, ConfigureNotificationSettings.
- The TimeSpentInAppPreferenceController use the LiveDataController.

Fixes: 135299529
Bug: 137558156
Test: compilation
Change-Id: I455a16536c9966184f1b2bd81d1f1217f3e09f9d
2020-05-04 10:34:23 +08:00
Bill Yi
37c795af3a Import translations. DO NOT MERGE
Auto-generated-cl: translation import
Change-Id: I76a7e3b5737e53869bee71cb8f8bbab9dbb40fc1
2020-05-01 18:03:30 -07:00
TreeHugger Robot
d2f16b4a25 Merge "Center text even if string is long" into rvc-dev 2020-05-01 14:20:23 +00:00
Arc Wang
0a8c3b0420 Merge "Set usage graph LTR layout direction for Persian & Urdu" into rvc-dev 2020-05-01 13:16:08 +00:00
Alex Johnston
cf342c9581 Merge "Update work challenge header in Settings" into rvc-dev 2020-05-01 10:10:49 +00:00
Arc Wang
7e40584e5d Merge "[Wi-Fi] Enhance com.android.settings.wifi.p2p unit test cases." into rvc-dev 2020-05-01 04:52:30 +00:00
Quang Luong
0ddc3675c4 Remove Connect/Disconnect button dependence on WifiEntry.isExpired()
WifiEntry.canConnect() may be true even if isExpired() is true, such as
in the case of connecting to renew a subscription. Thus, the
connect/disconnect button should only rely on canConnect() and
canDisconnect() (as well as the intermediate state of connecting) to
determine its visibility.

Bug: 150384136
Test: manually install expired passpoint profile and verify if the
connect button is visible and working.

Change-Id: Ibfdf285f3b97fd0de88804d4658df20bd67bf8e0
2020-04-30 20:36:32 -07:00
govenliu
4d74ae2e67 [Wi-Fi] Enhance com.android.settings.wifi.p2p unit test cases.
Add new unit test cases in WifiP2pSettingsTest.java, the coverage rate will raise from 30% to 71%.

Bug: 151696220
Test: make RunSettingsRoboTests ROBOTEST_FILTER=WifiP2pSettingsTest
Change-Id: I214866efae47a99e75178beca48deb398b70f9bd
2020-05-01 09:00:10 +08:00
Lucas Dupin
665c36eae2 Create QS media player setting
Test: make RunSettingsRoboTests ROBOTEST_FILTER=QuickSettingsMediaPlayerPreferenceControllerTest
Test: manual
Fixes: 155315021
Change-Id: I2583b985710898d0480f599fc9b5a2451c8950a7
2020-04-30 12:04:23 -07:00
Julia Reynolds
815ee670c9 Center text even if string is long
Test: manual in Armenian language
Fixes: 154930071
Change-Id: I61a84958a2043d36241b6fa5eff8dcb2c7ef0db0
2020-04-30 13:05:04 -04:00
TreeHugger Robot
6debb6a775 Merge "Add keyword for app pinning setting" into rvc-dev 2020-04-30 15:49:19 +00:00
TreeHugger Robot
4f244f6b88 Merge "Fix missing zone strings in some cases" into rvc-dev 2020-04-30 14:32:40 +00:00
Edgar Wang
cf654356d6 Merge "Add metrics log for special cases in Lanugages & About page" into rvc-dev 2020-04-30 14:27:23 +00:00
Tsung-Mao Fang
d3b4b1043b Add keyword for app pinning setting
We change the "screen pinning" to "app pinning",
and we still want to let user can get same search result
when they query "screen pinning".

Test: Open search and query "screen pinning", see the app pinning result
Bug: 151332926
Change-Id: Ice49d6db39ce89aa84508587262d9529df726784
2020-04-30 21:24:53 +08:00
Yanting Yang
459e5e1636 Merge "Fix NPE crash when opening the app info from shortcut suggestion" into rvc-dev 2020-04-30 13:17:01 +00:00
Yanting Yang
855f704eca Merge "Remove index for Take call on of Sound page" into rvc-dev 2020-04-30 12:30:53 +00:00
Jason Hsu
a69eb462a8 Merge "Logs accessibility service user trigger status." into rvc-dev 2020-04-30 12:21:16 +00:00
TreeHugger Robot
8da9374ace Merge "A new ui flow for screen pinning feature" into rvc-dev 2020-04-30 12:09:54 +00:00
TreeHugger Robot
c4310e5980 Merge "Add icons to contextual Wi-Fi card header" into rvc-dev 2020-04-30 12:08:54 +00:00
Jason Chiu
5b260b0bd1 Merge "Refine contextual Bluetooth card behavior when Bluetooth is off" into rvc-dev 2020-04-30 10:44:06 +00:00
Jason Chiu
509c0119fb Add icons to contextual Wi-Fi card header
Fixes: 149666241
Test: robotest
Change-Id: I67076eb561bc496b272b28dc54bce8845d8d622f
2020-04-30 18:34:33 +08:00
Tsung-Mao Fang
ae661a0782 A new ui flow for screen pinning feature
The purpose of this change is to resolve a number of security issue
around screen pinning.
See more detail go/screen-pinning-allows

There're a few change for Settings app.

- Rename the screen pinning to app pinning.
- Change the string description for app pinning.
- Pop up a warning dialog while user is enabling this feature.

Test: Rebuilt rom and see new ui flow.
Bug: 151332926
Change-Id: Ife07d7b95ab5dccb2aed7f2bc8fa32f97763bd63
2020-04-30 17:28:05 +08:00
Edgar Wang
329b20a445 Add metrics log for special cases in Lanugages & About page
Bug: 137559984
Test: robotest

Change-Id: I007282d8c4d5f9c6168dd84f6feee7e237ec7c42
2020-04-30 17:19:52 +08:00
Arc Wang
1efd7878c7 [Wi-Fi] Modify NetworkRequestDialog title & summary
Design change for UX improvement.

Bug: 155348488
Test: manual visual
Change-Id: I07d441f6fda8017cc9f4561ef64d57ff8db86f0f
2020-04-30 15:34:43 +08:00
TreeHugger Robot
136c101001 Merge "Twilight Location off text" into rvc-dev 2020-04-30 04:34:42 +00:00
TreeHugger Robot
9fd2ebf9ea Merge "Add "Play <APP> to" string" into rvc-dev 2020-04-30 04:10:39 +00:00
Blake Kragten
6fe60521d1 Merge "Remove enhanced connectivity switch for non-pixel" into rvc-dev 2020-04-30 03:24:52 +00:00
Jay Aliomer
41ee5663ab Twilight Location off text
When location is disabled, dark theme and night light
will show text and button to take the user to location page

Fixes: 153115261
Fixes: 153115618
Test: manually turn off location and observe view
Change-Id: I24be2f26a4c9e1b3f2a17e83e6f91cb7685f2e28
2020-04-29 23:14:32 -04:00
Tim Peng
be4ed2a3cb Add "Play <APP> to" string
Bug: 155345595
Test: build pass
Change-Id: Ib656f0db2efa6f777ada2c2565493775e72634ae
2020-04-30 02:13:24 +00:00
Yanting Yang
9dc0a45fd8 Fix NPE crash when opening the app info from shortcut suggestion
It occurs NPE in invoking refreshUi() of AppButtonsPreferenceController
when user fully install the instant app from google play and then
directly open app info from the shortcut suggestion in launcher.

Root cause:
AppButtonsPreferenceController.refreshUi() will be invoked when user
directly open app info from the shortcut suggestion in launcher. In
refreshUi(), we will update the information of button preference, but
the preferences will not be initialized if device existed an instant
version for the app.

Solution:
Check button preference and initial them if need in refreshUi().

Fixes: 137854835
Test: visual, robotests
Change-Id: Id5c3e53b9db2683cab970c10eace7925d889eea3
2020-04-30 08:53:16 +08:00