Commit Graph

71952 Commits

Author SHA1 Message Date
Janis Danisevskis
c90b511239 Merge "Keystore 2.0: Remove references to Keystore 1.0" am: 7aa99fe966
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1624590

Change-Id: I75e8e09c230cfb805ab3b2d6699aca2cd2514eac
2021-03-23 03:51:26 +00:00
Janis Danisevskis
7aa99fe966 Merge "Keystore 2.0: Remove references to Keystore 1.0" 2021-03-23 03:14:28 +00:00
Janis Danisevskis
75a91836e7 Keystore 2.0: Remove references to Keystore 1.0
Test: N/A
Bug: 171305684
Change-Id: I8b50c024e919d5b98348b792e0769c510ff1a33d
2021-03-22 13:35:53 -07:00
SongFerng Wang
d1278a3d3d Merge "KEY_CARRIER_NR_AVAILABILITIES_INT_ARRAY change type as IntArray" am: 5292baf810
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1645427

Change-Id: I9acfb31454bc8d63480adc64311717c07715d6f0
2021-03-22 19:22:27 +00:00
SongFerng Wang
5292baf810 Merge "KEY_CARRIER_NR_AVAILABILITIES_INT_ARRAY change type as IntArray" 2021-03-22 19:06:48 +00:00
Bonian Chen
de520dd11a Merge "[Settings] Rollback design for getSystemService(String)" am: 7a8463dbf8
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1648047

Change-Id: Ib628d337f511f67b88f34f6ef426d21a6176d817
2021-03-22 12:40:43 +00:00
Bonian Chen
7a8463dbf8 Merge "[Settings] Rollback design for getSystemService(String)" 2021-03-22 11:57:51 +00:00
Bonian Chen
0fd51cc9ea [Settings] Rollback design for getSystemService(String)
Some of the design are intented for getSystemService(String).
Rollback those items.

Bug: 179640862
Test: local
Change-Id: I581070afb380a86c6352322f927c269b4527aee9
2021-03-22 09:44:22 +00:00
Bonian Chen
70f887af52 Merge "[Settings] Convert to getSystemService(Class<T>)" am: 13fb77c652
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1645152

Change-Id: I3c76b1bf371a7bd8ecaea8b8c23a4a908e8b2c06
2021-03-22 08:56:33 +00:00
Bonian Chen
5734490d23 Merge "[Settings] Support getSystemService(Class<T>)" am: 513da92357
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1639943

Change-Id: Id7a6f8c0c21d2bf5112a91554f608974586588c1
2021-03-22 08:56:21 +00:00
Bonian Chen
13fb77c652 Merge "[Settings] Convert to getSystemService(Class<T>)" 2021-03-22 08:18:59 +00:00
Bonian Chen
513da92357 Merge "[Settings] Support getSystemService(Class<T>)" 2021-03-22 08:18:59 +00:00
SongFerngWang
e88740eae2 KEY_CARRIER_NR_AVAILABILITIES_INT_ARRAY change type as IntArray
Bug: 179814490
Test: build pass
Change-Id: I9d2abe1abe3082267ed64b71602d8ada21c95c6c
Merged-In: I9d2abe1abe3082267ed64b71602d8ada21c95c6c
2021-03-22 07:17:22 +00:00
Bonian Chen
db6c47756d [Settings] Convert to getSystemService(Class<T>)
Change to getSystemService(Class<T>) to align the capability with framework
part.

Bug: 179640862
Test: local
Change-Id: I1b4812044fc4876bec6645570049a60f9470dbbd
2021-03-22 06:20:19 +00:00
SongFerng Wang
b3f2e9090a Merge "Change the behavior of notifyAllowedNetworkTypesChanged." am: 3ac3cce15b
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1641828

Change-Id: I74750b2abd69c47b753cd3ee6e69e4ec1bbd7339
2021-03-22 03:12:24 +00:00
SongFerng Wang
3ac3cce15b Merge "Change the behavior of notifyAllowedNetworkTypesChanged." 2021-03-21 16:45:59 +00:00
Chiachang Wang
0080dfa65d Merge "Remove hidden connectivity methods access" am: 3e737c11db
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1644546

Change-Id: I3d2e0a9d19ceb8c9857f1bccb81a4dcea99f4831
2021-03-19 08:30:45 +00:00
Chiachang Wang
33855bfd7e Merge "Replace the way to get the network for no internet dialog" am: f26f579c8d
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1644547

Change-Id: Ic6d6eff65a4047754726ad72a3f66f0ab6ae3710
2021-03-19 08:27:56 +00:00
Chiachang Wang
3e737c11db Merge "Remove hidden connectivity methods access" 2021-03-19 08:13:06 +00:00
Chiachang Wang
f26f579c8d Merge "Replace the way to get the network for no internet dialog" 2021-03-19 07:54:24 +00:00
Jeremy Goldman
218ca3cbe9 Merge "Add goldmanj to the Settings' vpn2 directory Owners file" am: 19c5d0a749
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1634463

Change-Id: I22f165eba9482a6493e4e2bf7ce487208e6c0cf5
2021-03-19 06:43:58 +00:00
Jeremy Goldman
19c5d0a749 Merge "Add goldmanj to the Settings' vpn2 directory Owners file" 2021-03-19 06:15:40 +00:00
Chiachang Wang
eedfa1d307 Remove hidden connectivity methods access
This commit resolves the hidden methods accesses for
LinkProperties, IpConfiguration and RouteInfo with atlernative
way for the connectivity mainline module preparation.

Bug: 172183305
Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
com.android.settings.wifi.details2.WifiDetailPreferenceController2Test
Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
com.android.settings.wifi.details.WifiDetailPreferenceControllerTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
com.android.settings.UtilsTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
com.android.settings.wifi.WifiConfigController2Test
Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
com.android.settings.wifi.WifiConfigController2Test

Change-Id: Iec4dab5d9fa12dedcf69a1cfe2a8be0956bc0d79
Merged-In: Iec4dab5d9fa12dedcf69a1cfe2a8be0956bc0d79
2021-03-18 22:25:05 +08:00
Chiachang Wang
b64bf233a3 Merge "Update mocking to correct target methods" am: efa884758b
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1644306

Change-Id: I2d68748adf0154af2a3b9017d4510041af5baf12
2021-03-18 13:53:11 +00:00
Chiachang Wang
efa884758b Merge "Update mocking to correct target methods" 2021-03-18 13:16:14 +00:00
Chiachang Wang
11c37350d9 Replace the way to get the network for no internet dialog
It's a refactor work for incoming connectivity mainline. The
network information contained in the no ineternet notification
action was placed the target network id. The receiver which is
Settings will need to construct the network from the network id
using the hidden Network constructor. Since Network is moving
into module, Settings will not be able to access it. Apps should
use Network instead of network id, so just send the network
object to Settings.

Update the corresponding logic in Settings.

Bug: 172183305
Test: manually test with no internet dialog and check the
      behavior and log
Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
      com.android.settings.wifi.WifiNoInternetDialogTest
Change-Id: I75c04d6f1c2159ae990f6015551eb39d99266336
2021-03-18 11:35:05 +00:00
Chiachang Wang
6290ad9509 Update mocking to correct target methods
The correct target context should use the mActivity in
MobileNetworkSettingsTest, so that the mocking for
telephony service could correctly applied.

Both AutoTimeZonePreferenceControllerTest and
BasebandVersionPreferenceControllerTest refer to the lib
implemented shadow Connectivitymanager but that does not
the correct reference after utils class being updated.
Update the test logic inside to refer to correct method.
The reference to ShadowConnectivityManager does not needed
anymore so remove it from the test.

Fix: 183068151
Fix: 183067742
Fix: 183068139
Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
com.android.settings.network.telephony.MobileNetworkSettingsTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
com.android.settings.datetime.AutoTimeZonePreferenceControllerTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings\
.deviceinfo.firmwareversion.BasebandVersionPreferenceControllerTest

Change-Id: I15ecc6aab7d530d20cd23b06267cc184a2c62b40
2021-03-18 14:53:07 +08:00
Treehugger Robot
207fa629bc Merge "Replace hidden CM#isNetworkSupported() usage" am: 959325e88a
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1639940

Change-Id: I7aa0702f04c1f876851661ea54ba289b5eb9234d
2021-03-18 03:25:20 +00:00
Chiachang Wang
3ad73342c7 Merge "Replace the hidden ProxyInfo methods usage" am: 2f66e59e05
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1641827

Change-Id: If019c9b540f58e82b250693ed05dfabcda2c7c66
2021-03-18 03:19:28 +00:00
Treehugger Robot
959325e88a Merge "Replace hidden CM#isNetworkSupported() usage" 2021-03-18 02:39:21 +00:00
Chiachang Wang
2f66e59e05 Merge "Replace the hidden ProxyInfo methods usage" 2021-03-18 02:37:00 +00:00
Chiachang Wang
cda53ebeae Merge "Replace the way to access StaticIpConfiguration" am: dd61e5d664
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1641821

Change-Id: I6794a8d8113b5167b24e875554bc54b9155dd97f
2021-03-18 00:42:40 +00:00
Chiachang Wang
dd61e5d664 Merge "Replace the way to access StaticIpConfiguration" 2021-03-18 00:23:14 +00:00
Chiachang Wang
d507dc19b1 Replace hidden CM#isNetworkSupported() usage
It's a refactor work for connectivity mainline module. The
hidden methods access is no longer allowed, so the usage for
isNetworkSupported() should be replaced. Settings use it to
check if device support telephony, wifi or ethernet service.
There are alternative methods to check if device supports such
features. Replace as it is.

Bug: 172183305
Test: m ; make RunSettingsRoboTests
Change-Id: I8f1d11558b1be575a0777ed195abe027e838cb74
Merged-In: I8f1d11558b1be575a0777ed195abe027e838cb74
2021-03-17 15:22:40 +00:00
SongFerngWang
2166de23f3 Change the behavior of notifyAllowedNetworkTypesChanged.
Bug: 180903931
Test: atest AllowedNetworkTypesListenerTest.java
Change-Id: Ic94816415920bf25896ef2b198e228f369039c94
Merged-In: Ic94816415920bf25896ef2b198e228f369039c94
2021-03-17 21:20:21 +08:00
Chiachang Wang
eb16ebd14a Replace the hidden ProxyInfo methods usage
The hidden ProxyInfo methods usage should be replaced because
ProxyInfo is moving to connectivity mainline module. Setting
will not be able to access it. Replace the usage with
corresponding APIs.

Bug: 172183305
Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
      com.android.settings.wifi.WifiConfigControllerTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
      com.android.settings.wifi.WifiConfigController2Test
Test: manually update proxy from setting and check the result
Change-Id: I59192d0d5d38c833eb83cc930e358a738ebe3d13
2021-03-17 12:47:22 +00:00
Chiachang Wang
b16da1a9ca Replace the way to access StaticIpConfiguration
StaticIpConfiguration is a part of incoming connectivity
mainline module. The hidden variable is not accessible for
module outside. The caller should use getter and builder
to access it. Replace the usage with the formal way.

Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
      com.android.settings.wifi.WifiConfigControllerTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=\
      com.android.settings.wifi.WifiConfigController2Test
Change-Id: I2ccd427ba19a4ec7df863c38ee0b34cf0be87fa5
2021-03-17 11:30:11 +00:00
Lucas Lin
ddbd32432e Merge "Change the parameter type from ContentResolver to Context" am: 5ee7a7d07d
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1639939

Change-Id: I2492c9b4e7bb5b34ad6b3719525e8b00433d2778
2021-03-17 07:02:17 +00:00
Lucas Lin
5ee7a7d07d Merge "Change the parameter type from ContentResolver to Context" 2021-03-17 06:35:21 +00:00
Bonian Chen
49cdb602ea [Settings] Support getSystemService(Class<T>)
Add getSystemService(Class<T>) to align the capability with framework
part.

Bug: 179640862
Test: local
Change-Id: I278951c2402aa8551cee37923f45626ab1830dd3
2021-03-17 13:32:32 +08:00
Bonian Chen
c27980c1a9 Merge "[Settings] Code refactor - remove unused import lines" am: d248042a02
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1639941

Change-Id: I365757ae7bb17cabb39e377eb23aaf4ac97013b9
2021-03-16 14:09:39 +00:00
Bonian Chen
d248042a02 Merge "[Settings] Code refactor - remove unused import lines" 2021-03-16 13:47:28 +00:00
Bonian Chen
203f0fe89d [Settings] Code refactor - remove unused import lines
Remove some unused import lines within source code based on
https://source.android.com/setup/contribute/code-style

Bug: 182867979
Test: build pass
Change-Id: I76dbcfa9e5b435b2838401dfee15b12f472d07d0
2021-03-16 10:24:24 +00:00
lucaslin
11e738c3a0 Change the parameter type from ContentResolver to Context
Context is more useful than ContentResolver, it can provide more
information if we want to change the behavior in the future.

Bug: 172183305
Test: make RunSettingsRoboTests \
      ROBOTEST_FILTER=PrivateDnsPreferenceControllerTest
Test: make RunSettingsRoboTests \
      ROBOTEST_FILTER=PrivateDnsModeDialogPreferenceTest
Change-Id: I6c06460b67f81112db311f0739457d5f1e2e4554
Merged-In: I6c06460b67f81112db311f0739457d5f1e2e4554
2021-03-16 09:36:12 +00:00
Lucas Lin
73c971a5af Merge "Use getPrivateDnsMode() to get the value of private DNS" am: 159f261889
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1620600

Change-Id: I2ce646a34a7fc521b42c221faadfe6779f1c5ca4
2021-03-16 08:06:34 +00:00
Lucas Lin
159f261889 Merge "Use getPrivateDnsMode() to get the value of private DNS" 2021-03-16 07:39:35 +00:00
Treehugger Robot
c38b502c4a Merge "Add OWNER to network/datausage/wifi path" am: 56834d2ce3
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1635179

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I4d177c825df890a2d8947173e85ddd401e9f7361
2021-03-15 11:30:18 +00:00
Treehugger Robot
56834d2ce3 Merge "Add OWNER to network/datausage/wifi path" 2021-03-15 11:02:28 +00:00
Chiachang Wang
201429b683 Merge "Replace the hidden getActiveLinkProperties usage" am: d709b55250
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1635200

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I3d7e876c9fb8bf81a300b6b76154672e0d3b04c7
2021-03-15 10:14:46 +00:00
Chiachang Wang
d709b55250 Merge "Replace the hidden getActiveLinkProperties usage" 2021-03-15 09:42:16 +00:00