Promote DevicePolicyManager.packageHasActiveAdmins for Play Store
Promote API to @SystemApi so Play Store can call it. This is
done as a prerequisite for being able to call
ActivityManager.forceStopPackage.
Test: Patch in GTS tests in ag/1775696.
Bug: 34228363
Change-Id: Ic309f350947a5ae937493d6696b7af914fa7ab54
diff --git a/core/java/android/app/admin/DevicePolicyManager.java b/core/java/android/app/admin/DevicePolicyManager.java
index 6f73388..e08f466 100644
--- a/core/java/android/app/admin/DevicePolicyManager.java
+++ b/core/java/android/app/admin/DevicePolicyManager.java
@@ -1422,6 +1422,7 @@
* or uninstalled.
* @hide
*/
+ @SystemApi
public boolean packageHasActiveAdmins(String packageName) {
return packageHasActiveAdmins(packageName, myUserId());
}