Commit Graph

17 Commits

Author SHA1 Message Date
Bill Yi
daf09693e8 Import translations. DO NOT MERGE
Change-Id: I36e1a8823e69d09befa58f820f4e1356e4dd3e2b
Auto-generated-cl: translation import
2019-11-08 21:32:59 -08:00
Sunny Goyal
87fccf0720 Removing unnecessary R.java declaration for subpackages, to make gradle setup simpler
Removed:
  com.android.settingslib.restrictedlockutils
  com.android.settingslib.helputils
  com.android.keyguard

Moving sysui settings to use sysui settings resource package name

Test: Everything compiles / presubmit
Bug: 130289146
Change-Id: I5d760fa2f04439d24b455839f7bdd5cc499e840f
2019-08-14 12:08:44 -07:00
Irina Dumitrescu
aa2d705440 The AdminSupportDetails intent creation preserves the original admin user ID.
When the admin user ID is null, UserHandle.NULL which has value -1000.

Test: atest RestrictedLockUtilsTest
Fixes: 118881180
Change-Id: I4958e168c9b99e16d8640718aefe306a5fb3504b
2019-05-09 15:59:28 +00:00
Daisuke Niwa
fc63619d49 Avoid NPE when accessing to EnforcedAdmin
NPE happens when "modify" is tapped on the carrier wifi network
connected using CarrierConfig information. null is passed to
sendShowAdminSupportDetailsIntent method through 2nd argument.

Bug: 128188146
Test: Manually verified the crash scenario
Test: RunSettingsLibRoboTests
Signed-off-by: Daichi Ueura <daichi.ueura@sony.com>
(Cherry-pick from pa/1302748)
Change-Id: If92c12041b91dbab0f083a1b49d263b201e87699
2019-04-15 13:09:58 -07:00
Philip P. Moltmann
477666d963 No need for getProfileOwnerForUser as SystemApi
Rather use
context.createPackageContextAsUser(context.getPackageName(), 0, user)
        .getSystemService(DevicePolicyManager.class).getProfileOwner();

Test: Looked at permission restricted by device owner in UI
Fixes: 126699845
Change-Id: I3dc16fbe360aaeb416c526cacf5f55ce2c3a1b20
2019-03-18 18:43:40 +00:00
Sunny Goyal
f1ea4f0e8f Removing some unnecessary packages, to simplify AndroidStudio setup
Test: Everything builds
Change-Id: I0b649eb9f6b0ad07def59d0d6f7b3e70ef64acf1
2019-03-14 12:15:43 -07:00
Bill Yi
e5f6df6f17 Import translations. DO NOT MERGE
Change-Id: Iab916f0d073867f800b8da088bb3cc35299c3aa9
Auto-generated-cl: translation import
2019-02-01 22:10:10 -08:00
TreeHugger Robot
38d0bd0634 Merge "Set EXTRA_USER instead of EXTRA_USER_ID for ACTION_SHOW_ADMIN_SUPPORT_DETAILS" 2018-10-17 00:26:37 +00:00
Philip P. Moltmann
125f042c05 Merge "Rename recently added symbols to camel-case" 2018-10-15 17:16:55 +00:00
Philip P. Moltmann
54118289e5 Merge "Use public method in RestrictedLockUtils#isCurrentUserOrProfile" 2018-10-15 16:41:53 +00:00
Philip P. Moltmann
9c7f51e676 Rename recently added symbols to camel-case
Test: looked at help screen in settings
      make RunSettingsLibRoboTests
Change-Id: Ife257ad1bbe43a42084fdf9d2718c8fc1465f170
Fixes: 116797641
2018-10-12 10:55:24 -07:00
Philip P. Moltmann
c54c36dcc7 Set EXTRA_USER instead of EXTRA_USER_ID for ACTION_SHOW_ADMIN_SUPPORT_DETAILS
Test: Built
Bug: 116798569
Change-Id: I60e8e9613c20d860ff8fda682e9f754ee66dcbef
2018-10-10 15:51:47 -07:00
Philip P. Moltmann
54ff6b0138 Use public method in RestrictedLockUtils#isCurrentUserOrProfile
No need for new system API

Test: Built
Bug: 116798569
Change-Id: Iec6b29f8e47037854b36556a03e1f044dcaa5136
2018-10-09 15:58:50 -07:00
Philip P. Moltmann
0ada0a6044 Change DevicePolicyManager APIs as requested
This requires RestrictedLockUtils to change which then causes further
changes.

I left the old APIs available for non-system-api customers.

Test: RunSettingsLibRoboTests
Bug: 116798569
Change-Id: Id5384ee074bb245e615012b7e0d5298b8bf27ba4
2018-10-09 12:38:23 -07:00
Bill Yi
52235e150d Import translations. DO NOT MERGE
Change-Id: I1ffe559827ae4b1020934fc54c1425454087dfae
Auto-generated-cl: translation import
2018-09-22 09:56:37 -07:00
Philip P. Moltmann
2d21d77e78 Make restricted lock icon system-api
Bug: 110953302
Test: CtsVerifier -> BYOD Managed Provision -> Permission Lockdown (test
created a permission disabled by admin)
Change-Id: I042668225227aabc9655d83307e60f7efe399d8d
2018-09-13 09:56:41 -07:00
Philip P. Moltmann
4e615e6986 Factor some RestrictedLockUtils out of SettingLib
Also make the new lib only use system-apis.

This allows mainline module to use the new
RestrictedLockUtilsSettingLib.

Unfortunately the whole RestrictedLockUtils would have caused to much
new system-api. Hence it was split into RestrictedLockUtils and
RestrictedLockUtilsInternal. This caused a lot of trivial code changes.

Bug: 110953302
Test: Built
Change-Id: I693b3bf56f3be71f0790776e3aad5694717786ef
2018-08-30 11:59:29 -07:00