Commit Graph

72171 Commits

Author SHA1 Message Date
Bonian Chen
8cd695efea Merge "[Settings] Support getSystemService(Class<T>)" am: 513da92357 am: 5734490d23
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1639943

Change-Id: I2630ee28b766890d36bbc4c360eeb19d07ef73d7
2021-03-22 09:36:14 +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
513da92357 Merge "[Settings] Support getSystemService(Class<T>)" 2021-03-22 08:18:59 +00:00
SongFerng Wang
34c8d35cd3 Merge "Change the behavior of notifyAllowedNetworkTypesChanged." am: 3ac3cce15b am: b3f2e9090a
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1641828

Change-Id: I5ba679ca3d2a6f6411dae1ffdc441527508d4763
2021-03-22 03:56:36 +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
6c7f70908e Merge "Remove hidden connectivity methods access" am: 3e737c11db am: 0080dfa65d
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1644546

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

Change-Id: I44ab529b8251c1f4630186c74ba2d16b5030e104
2021-03-19 09:02:20 +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
8e8d13fd83 Merge "Add goldmanj to the Settings' vpn2 directory Owners file" am: 19c5d0a749 am: 218ca3cbe9
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1634463

Change-Id: Ida896c587d2d02de4ccdee7faf41f25d15f9f232
2021-03-19 07:23:09 +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
Weng Su
7772bf587f [automerger skipped] Merge "[DO NOT MERGE] Revert "[Security Report] Fix Settings WifiScanModeActivity Overlaid issue"" into pi-dev am: 56dc96d1f6 -s ours am: 1e8d908cfc -s ours am: 1a4cf947f5 -s ours am: 097d262fda -s ours am: faa183cb7b -s ours
am skip reason: skip tag Change-Id Ia7acad6d456ce5ebea2d982d4cb063d4f28cbfff with SHA-1 58b0f2d5b3 is already in history. Skip tag was found from reverted change Ia7acad6d456ce5ebea2d982d4cb063d4f28cbfff

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/13910509

Change-Id: I8f6d70e727e3ec61f6fcd7fdd8059bf3718395cd
2021-03-19 05:46:36 +00:00
Weng Su
faa183cb7b [automerger skipped] Merge "[DO NOT MERGE] Revert "[Security Report] Fix Settings WifiScanModeActivity Overlaid issue"" into pi-dev am: 56dc96d1f6 -s ours am: 1e8d908cfc -s ours am: 1a4cf947f5 -s ours am: 097d262fda -s ours
am skip reason: skip tag Change-Id Ia7acad6d456ce5ebea2d982d4cb063d4f28cbfff with SHA-1 58b0f2d5b3 is already in history. Skip tag was found from reverted change Ia7acad6d456ce5ebea2d982d4cb063d4f28cbfff

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/13910509

Change-Id: Ie109931c17fd62c42a4fb88c32866f42347e6c48
2021-03-19 05:01:43 +00:00
Weng Su
097d262fda [automerger skipped] Merge "[DO NOT MERGE] Revert "[Security Report] Fix Settings WifiScanModeActivity Overlaid issue"" into pi-dev am: 56dc96d1f6 -s ours am: 1e8d908cfc -s ours am: 1a4cf947f5 -s ours
am skip reason: subject contains skip directive

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/13910509

Change-Id: Icd1b51ce7924bd3362fe3a1bd37b9ea1043bc03b
2021-03-19 04:23:28 +00:00
Weng Su
1a4cf947f5 [automerger skipped] Merge "[DO NOT MERGE] Revert "[Security Report] Fix Settings WifiScanModeActivity Overlaid issue"" into pi-dev am: 56dc96d1f6 -s ours am: 1e8d908cfc -s ours
am skip reason: skip tag Change-Id Ia7acad6d456ce5ebea2d982d4cb063d4f28cbfff with SHA-1 faa5f6b5f6 is already in history. Skip tag was found from reverted change Ia7acad6d456ce5ebea2d982d4cb063d4f28cbfff

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/13910509

Change-Id: I7f8489b6c9d256a98b5d4f0dbb30231a1c542cc0
2021-03-19 04:02:57 +00:00
Weng Su
1e8d908cfc [automerger skipped] Merge "[DO NOT MERGE] Revert "[Security Report] Fix Settings WifiScanModeActivity Overlaid issue"" into pi-dev am: 56dc96d1f6 -s ours
am skip reason: subject contains skip directive

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/13910509

Change-Id: I0673d0d8115819b39f0d9c3270dc2e98be11c2de
2021-03-19 03:29:28 +00:00
Weng Su
56dc96d1f6 Merge "[DO NOT MERGE] Revert "[Security Report] Fix Settings WifiScanModeActivity Overlaid issue"" into pi-dev 2021-03-19 02:51:52 +00:00
Chiachang Wang
7dce573e9d Merge "Update mocking to correct target methods" am: efa884758b am: b64bf233a3
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1644306

Change-Id: I8fed607cd748348e714470f5fe8159abe445313d
2021-03-18 14:29:12 +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
Weng Su
f4432df069 [DO NOT MERGE] Revert "[Security Report] Fix Settings WifiScanModeActivity Overlaid issue"
This reverts commit 32d5d3a3a3.

Bug: 174047492
Reason for revert:
Look like the WindowManager.LayoutParams.SYSTEM_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS system flag is not supported in the pi-dev branch.

Change-Id: Iec3c28e8c148f83fc171d696b2fc67f359d03eb8
2021-03-18 09:02:20 +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
e5dfff612b Merge "Replace hidden CM#isNetworkSupported() usage" am: 959325e88a am: 207fa629bc
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1639940

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

Change-Id: I7e7ec3721de73523f52718665bc1763f75184a56
2021-03-18 03:41:16 +00: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
f60f9ec14c Merge "Replace the way to access StaticIpConfiguration" am: dd61e5d664 am: cda53ebeae
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1641821

Change-Id: Ie3a809e901745d7143d0b2b48023f2ddd3671480
2021-03-18 01:18:45 +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
5c73826020 Merge "Change the parameter type from ContentResolver to Context" am: 5ee7a7d07d am: ddbd32432e
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1639939

Change-Id: I1e1a332f52f0dff1dda585912e5cc41ab5296156
2021-03-17 07:20:45 +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
TreeHugger Robot
2bec77689e Merge "Only display single line for title" into rvc-qpr-dev am: a5ea519cc6
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/13849828

Change-Id: I8972ff3ca02d7ebd435f65a8eef5228b9a20fbc5
2021-03-16 23:54:35 +00:00
TreeHugger Robot
a5ea519cc6 Merge "Only display single line for title" into rvc-qpr-dev 2021-03-16 23:29:09 +00:00
Bonian Chen
d42d9a41f6 Merge "[Settings] Code refactor - remove unused import lines" am: d248042a02 am: c27980c1a9
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Settings/+/1639941

Change-Id: I8efdc871c29a6c56aacf7a1b553a20c9cafc765d
2021-03-16 14:45:42 +00: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