Commit Graph

9252 Commits

Author SHA1 Message Date
Sunny Shao
01d6f05f53 Use Builder to replace the Uitls.addFooterPreference
Fixes: 139163212
Test: manual test
Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.bluetooth
Change-Id: I223e4a234d07e5b95ebb9478f0888a4828e8e64d
2019-08-09 17:03:12 +08:00
Sunny Shao
7e866b670e Use Builder to replace the Uitls.addFooterPreference
Fixes: 139163212
Test: manual test
Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.bluetooth
Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.accounts
Change-Id: I861434b81c07db785e6f1cfb3e34871ffba41e5f
2019-08-09 11:42:04 +08:00
TreeHugger Robot
fa9e685fff Merge "Use FooterPreference in xml explicitly" 2019-08-09 00:25:22 +00:00
Sunny Shao
660b36e061 Use FooterPreference in xml explicitly
- Removed the FooterPreferenceMixin from the BluetoothDetailsMacAddressController.
 - Added the common api addFooterPreference.

Fixes: 139104386
Test: manual test
Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.bluetooth
Change-Id: Iab40fa4c5be674290b1dc6d372c84609ccc2ea49
2019-08-08 18:42:26 +08:00
Sunny Shao
fb695782c5 Use FooterPreference in xml explicitly
Removed the FooterPreferenceMixin from the BillingCycleSettings page.

Fixes: 139099367
Test: manual test
Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.datausage
Change-Id: I408e433b3366a617b6c5a6fdb18f4830de4b8287
2019-08-08 16:25:14 +08:00
Sunny Shao
6b4a22522b Use FooterPreference in xml explicitly
Removed the FooterPreferenceMixin from the ChooseAccountFragment page.

Fixes: 139043643
Test: manual test
Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.accounts
Change-Id: I2b6ebef7f8ca0684afd75ec9bdd742a78a771bcd
2019-08-07 17:01:25 +08:00
TreeHugger Robot
20f0faee70 Merge "Use FooterPreference in AccountSyncSettings page" 2019-08-06 15:18:33 +00:00
TreeHugger Robot
e69ef50ba2 Merge "Make EuiccService un-disable-able." 2019-08-06 14:56:22 +00:00
Sunny Shao
1908cb6bd2 Use FooterPreference in AccountSyncSettings page
.Use the new FooterPreference and removed the old FooterPreferenceMixin
 from the AccountSyncSettings page.
.Add the ShadowAuthenticationHelper for commnon shadow util.

Fixes: 138978130
Test: manual test
Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.accounts
Change-Id: I93ae46b3b66e7e504320a9ed120ab7948dd06423
2019-08-06 20:33:44 +08:00
Yi-Ling Chuang
7e2978ab58 Make EuiccService un-disable-able.
Disabling the eSIM Manager could leave the device in a bad state, unable
to address the eSIM, and possibly crash due to EuiccConnector failing to
find an LPA to implement EuiccService. So here we do not allow users to
disable this component.

Fixes: 135644632
Test: robotest
Change-Id: Ia4ea48b449f121edaff10531b7c975b09432a8f8
2019-08-06 17:58:08 +08:00
Stanley Wang
2862e79478 Merge "Revert "Fix app uninstalling/stopping possible in screen pinning mode"" 2019-08-06 06:17:11 +00:00
Stanley Wang
064b21e0b6 Revert "Fix app uninstalling/stopping possible in screen pinning mode"
This reverts commit 161c359508.

Reason for revert: This solution has a bug.

Change-Id: I925dab9b1a8d50de538a4fc652f722744fe3fadf
2019-08-06 03:44:02 +00:00
TreeHugger Robot
87ecb5deed Merge "Import RadioButtonPreference from SettingsLib" 2019-08-03 02:52:36 +00:00
Raff Tsai
d68802cf6d Fix robolectric test error
jobService is moved to mainline module. It is not registered in
the system at the beginning, therefore getSystemService returns
null. Instead of getSystemService, directly create a JobSchedulerImpl
and mock getSystemService method to return the JobSchedulerImpl
instance.

Fixes: 138714772
Test: make RunSettingsRoboTests
Change-Id: If91b6a63c0de92530d69f7b80515669352aab760
2019-08-02 10:22:20 +00:00
TreeHugger Robot
c078ee3b5d Merge "Add Tapjacking Protection for SettingsHomepageActivity" 2019-08-02 06:32:01 +00:00
Edgar Wang
677b943ae1 Merge "Add skip lock screen in Notification & security lock screen settings" into qt-r1-dev am: 8e3b202070 am: 3448917d8e
am: fc0aec7f1a

Change-Id: Icb23c10cf6f6b4bf4c8fcb81d23d1c2b8d7ddd33
2019-08-01 23:13:14 -07:00
Edgar Wang
fc0aec7f1a Merge "Add skip lock screen in Notification & security lock screen settings" into qt-r1-dev am: 8e3b202070
am: 3448917d8e

Change-Id: Ib451284c689f984e8064af58ef538b34e8ec6784
2019-08-01 23:00:21 -07:00
Edgar Wang
3448917d8e Merge "Add skip lock screen in Notification & security lock screen settings" into qt-r1-dev
am: 8e3b202070

Change-Id: Ic8c1eb744a1612fedd187902e65d7718500f4e8d
2019-08-01 22:49:22 -07:00
Edgar Wang
8e3b202070 Merge "Add skip lock screen in Notification & security lock screen settings" into qt-r1-dev 2019-08-02 05:38:23 +00:00
Youming Ye
34599f661d Check the missing useHomeWfMode case am: b7923f5a3f
am: de8c3c5fd3

Change-Id: I068d40471deb73869b0586e2bd4ebbba522ac85d
2019-08-01 11:41:05 -07:00
Youming Ye
de8c3c5fd3 Check the missing useHomeWfMode case
am: b7923f5a3f

Change-Id: I8ffa6acb13e07b4a28b8f46b348ffc47c143a317
2019-08-01 11:24:55 -07:00
Sunny Shao
647e49e7cf Add Tapjacking Protection for SettingsHomepageActivity
Add/remove the SYSTEM_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS flag into/from
SettingsHomepageActivity and SettingsPanelActivity with lifecycle.

Bug: 138442483
Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.homepage
      make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.panel
      manual test
Change-Id: I72f9a947f57f74a8c09127d6c39173594c248ddc
2019-08-01 23:36:12 +08:00
Raff Tsai
71a37d138b Import RadioButtonPreference from SettingsLib
Bug: 138620011
Test: manual, robolectric
Change-Id: I3b8a2be021a1b4a07aae61483f2329b7a5bd4655
2019-08-01 07:16:55 +00:00
Raff Tsai
5939f73740 Fix test case error
Bug: 138714772
Test: make RunSettingsRoboTests ROBOTEST_FILTER="com.android.settings.core.codeinspection"
Change-Id: I10ff1983793e1e158eb72e93d838ccda97728084
2019-08-01 12:22:03 +08:00
Edgar Wang
58a5be4401 Add skip lock screen in Notification & security lock screen settings
Users may have trouble finding this setting in face auth.
Heard this from dogfood/executive feedback and customer support discussion.
So add Skip Lock Screen preference in
Display > Lock screen display > What to show >
and
App & Notifications > Notifications > Lock Screen >

Bug: 138458558
Test: robotest & manual

Change-Id: I10e420821423821743d65b00c8b7e6d4d1224e00
2019-08-01 11:17:05 +08:00
Youming Ye
b7923f5a3f Check the missing useHomeWfMode case
Bug: 133812904
Test: Build
Change-Id: If89c67c0595808a1339517c6084f1d1e23f5974b
Merged-In: If89c67c0595808a1339517c6084f1d1e23f5974b
2019-07-31 16:38:32 -07:00
Antony Sargent
fa99ea7dc6 Merge "Protect entry points to add an eSIM when admin restricted" into qt-r1-dev am: 4685c785b9 am: ad2f49f851
am: bf2c5ce274

Change-Id: Ia0d2a348088ac2dc72e5b5218718aa80105d3e16
2019-07-31 16:35:58 -07:00
Antony Sargent
bf2c5ce274 Merge "Protect entry points to add an eSIM when admin restricted" into qt-r1-dev am: 4685c785b9
am: ad2f49f851

Change-Id: I3caaf466e7c62cee4de6ef2a4e9695e8725736f1
2019-07-31 16:06:59 -07:00
Antony Sargent
e744ee1295 Merge "Protect entry points to add an eSIM when admin restricted" into qt-r1-dev
am: 4685c785b9

Change-Id: I1ce1afeee9ab139ff47a1deec14d536c8c9529ad
2019-07-31 16:04:54 -07:00
Quang Luong
c2e859edee Merge "Copy WifiSettings base code into WifiSettings2 without WifiTracker" 2019-07-31 23:03:31 +00:00
Antony Sargent
ad2f49f851 Merge "Protect entry points to add an eSIM when admin restricted" into qt-r1-dev
am: 4685c785b9

Change-Id: I5792ff5333005e2e0c66fd24d594b79bf67d140c
2019-07-31 15:56:00 -07:00
TreeHugger Robot
4685c785b9 Merge "Protect entry points to add an eSIM when admin restricted" into qt-r1-dev 2019-07-31 22:39:22 +00:00
Antony Sargent
482415d37e Protect entry points to add an eSIM when admin restricted
If the DISALLOW_CONFIG_MOBILE_NETWORKS admin policy is set, we were
accidentally still allowing access to the flow where you add an eSIM
subscription via the "plus" button on the Network & internet page. While
fixing this, I also noticed that the mobile networks list page (which
only becomes available if you have multiple subscriptions) has a link at
the bottom to start the flow as well, and that wasn't being protected.

The fix for the plus button on the Network & internet page was just to
make sure not to call setEnabled(true) if the preference was already
disabled by admin policy, since that has the effect of overriding the
admin-disabling.

The fix for the mobile networks list page just needed to add the
relevant tags in the layout XML, and then we get it for free.

Fixes: 137627845
Test: make RunSettingsRoboTests
Change-Id: I896ac248f50aaeecc157791938a0a0a98265aa07
2019-07-31 12:53:39 -07:00
Quang Luong
b061428938 Copy WifiSettings base code into WifiSettings2 without WifiTracker
Copied main logic from WifiSettings into WifiSettings2, removing
all instances of WifiTracker in preparation of adding WifiTracker2.

Removed:
 - WifiDialog (to be added back in)
 - Context Menu (to be added back in)
 - Leftover SUW code (Next button)

WifiSettings2Test also copied directly from WifiSettingsTest, without
context menu test.

Bug: 70983952
Test: atest WifiSettings2Test

Change-Id: Ie1ef5bf0ca14f5989f4add2165422609f12c2c84
2019-07-31 11:46:15 -07:00
Raff Tsai
a64c7b2698 Merge "Fix Settings crash when click uninstall button" 2019-07-31 01:16:47 +00:00
Quang Luong
a5c8edb46f Merge "Default MAC address should display "Not Available" in network details" into qt-r1-dev am: 17908b1e8f am: 5c4a0e3444
am: b66a8c86a4

Change-Id: I2cfd0376d60efcc5fd417139bfcb3446a2485871
2019-07-30 17:37:41 -07:00
Quang Luong
b66a8c86a4 Merge "Default MAC address should display "Not Available" in network details" into qt-r1-dev am: 17908b1e8f
am: 5c4a0e3444

Change-Id: Ib5545caea7cce930898c81fc0158877416666f89
2019-07-30 17:26:35 -07:00
Quang Luong
5c4a0e3444 Merge "Default MAC address should display "Not Available" in network details" into qt-r1-dev
am: 17908b1e8f

Change-Id: Ie1cdb83f47bac988b93401b3994a096d85333ce6
2019-07-30 17:16:00 -07:00
Quang Luong
815af2ba6e Merge "Default MAC address should display "Not Available" in network details" into qt-r1-dev
am: 17908b1e8f

Change-Id: I0adf1cc87a31b4daa762baf67e2e99415b35491a
2019-07-30 17:12:17 -07:00
TreeHugger Robot
17908b1e8f Merge "Default MAC address should display "Not Available" in network details" into qt-r1-dev 2019-07-30 23:33:22 +00:00
Antony Sargent
74023e3057 Merge "Make EnabledNetworkModePreferenceController listen to setting changes" into qt-r1-dev am: 66208e734b am: 5a39d48ab2
am: 96c01305b2

Change-Id: Ife5f1280f1a4bc23223c862d97b1b4750a4c4575
2019-07-30 16:12:23 -07:00
Antony Sargent
96c01305b2 Merge "Make EnabledNetworkModePreferenceController listen to setting changes" into qt-r1-dev am: 66208e734b
am: 5a39d48ab2

Change-Id: I997f4cacaed95a2cc77af01cebc6d4452368d05e
2019-07-30 15:58:36 -07:00
Antony Sargent
5a39d48ab2 Merge "Make EnabledNetworkModePreferenceController listen to setting changes" into qt-r1-dev
am: 66208e734b

Change-Id: I7e1494a1859393844ad5810a9721bf3865ed5f75
2019-07-30 15:43:32 -07:00
Antony Sargent
9e58a8df39 Merge "Make EnabledNetworkModePreferenceController listen to setting changes" into qt-r1-dev
am: 66208e734b

Change-Id: Ifb4c387a8663fda3a642b03b68777079d1c5a619
2019-07-30 15:43:32 -07:00
Antony Sargent
6d910e8608 Make EnabledNetworkModePreferenceController listen to setting changes
The controller for the "Preferred network type" preference on the SIM
details page wasn't listening for changes to the underlying global
setting, so changes to the setting would be reflected in SysUI but not
on this page if it happened to be showing.

Bug: 135667565
Test: make RunSettingsRoboTests
Change-Id: I5dfe4843a681c613f49caf4584e9dbebc54e708a
2019-07-30 12:30:19 -07:00
Antony Sargent
0e6bbac235 Merge "Refesh mobile network details page on carrier config changes" into qt-r1-dev am: 985d3d570d am: 42861b21c9
am: 01028402ca

Change-Id: Iad136b22b968e3a454944d090ae0d6594669f1da
2019-07-30 10:43:38 -07:00
Antony Sargent
01028402ca Merge "Refesh mobile network details page on carrier config changes" into qt-r1-dev am: 985d3d570d
am: 42861b21c9

Change-Id: I1b1b85bbdac1e12c51c855686a5c25e5581a40e4
2019-07-30 10:15:54 -07:00
Antony Sargent
42861b21c9 Merge "Refesh mobile network details page on carrier config changes" into qt-r1-dev
am: 985d3d570d

Change-Id: Ic653102f8f66c0f5e1e3457750cdf150f1dbfd5e
2019-07-30 09:54:25 -07:00
Antony Sargent
20c9eff53e Merge "Refesh mobile network details page on carrier config changes" into qt-r1-dev
am: 985d3d570d

Change-Id: I02252dd85f3b11aef3109e1a0193faba8bb9c240
2019-07-30 09:54:25 -07:00
Raff Tsai
88228c3399 Fix Settings crash when click uninstall button
When mPackageName is null, mFinish is true. OnResume() doesn't
invoke refreshUI(). It causes uninstall button is still enabled.
The solution is hiding AppButtonsPreference when mFinish is true.

Fixes: 138524326
Test: make RunSettingsRoboTests ROBOTEST_FILTER
Change-Id: I9759e53f002afbd4c88d8d536df3bf01c343135e
2019-07-30 11:18:09 +08:00