Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 53fb73b9 authored by Kholoud Mohamed's avatar Kholoud Mohamed Committed by Android (Google) Code Review
Browse files

Merge "Remove no longer needed broadcasts" into sc-dev

parents 28d66d71 352849cc
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -396,8 +396,6 @@ package android.app.admin {
    method @RequiresPermission("android.permission.MANAGE_DEVICE_ADMINS") public void setNextOperationSafety(int, int);
    method @NonNull public static String unsafeOperationReasonToString(int);
    field public static final String ACTION_DATA_SHARING_RESTRICTION_APPLIED = "android.app.action.DATA_SHARING_RESTRICTION_APPLIED";
    field public static final String ACTION_MANAGED_PROFILE_CREATED = "android.app.action.MANAGED_PROFILE_CREATED";
    field public static final String ACTION_PROVISIONED_MANAGED_DEVICE = "android.app.action.PROVISIONED_MANAGED_DEVICE";
    field public static final int CODE_ACCOUNTS_NOT_EMPTY = 6; // 0x6
    field public static final int CODE_CANNOT_ADD_MANAGED_PROFILE = 11; // 0xb
    field public static final int CODE_DEVICE_ADMIN_NOT_SUPPORTED = 13; // 0xd
+0 −20
Original line number Diff line number Diff line
@@ -5472,26 +5472,6 @@ public class DevicePolicyManager {
    public static final String ACTION_SHOW_NEW_USER_DISCLAIMER =
            "android.app.action.ACTION_SHOW_NEW_USER_DISCLAIMER";
    /**
     * Broadcast action: notify managed provisioning that the device has been provisioned.
     *
     * @hide
     */
    @TestApi
    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
    public static final String ACTION_PROVISIONED_MANAGED_DEVICE =
            "android.app.action.PROVISIONED_MANAGED_DEVICE";
    /**
     * Broadcast action: notify managed provisioning that a new managed profile is created.
     *
     * @hide
     */
    @TestApi
    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
    public static final String ACTION_MANAGED_PROFILE_CREATED =
            "android.app.action.MANAGED_PROFILE_CREATED";
    /**
     * Widgets are enabled in keyguard
     */
+0 −4
Original line number Diff line number Diff line
@@ -690,10 +690,6 @@
    <!-- Made protected in S (was added in R) -->
    <protected-broadcast android:name="com.android.internal.intent.action.BUGREPORT_REQUESTED" />

    <!-- Added in S -->
    <protected-broadcast android:name="android.app.action.MANAGED_PROFILE_CREATED" />
    <protected-broadcast android:name="android.app.action.PROVISIONED_MANAGED_DEVICE" />

    <!-- ====================================================================== -->
    <!--                          RUNTIME PERMISSIONS                           -->
    <!-- ====================================================================== -->
+0 −18
Original line number Diff line number Diff line
@@ -16027,15 +16027,6 @@ public class DevicePolicyManagerService extends BaseIDevicePolicyManager {
                restrictRemovalOfManagedProfile(admin, userInfo.id);
            }
            final Intent intent = new Intent(DevicePolicyManager.ACTION_MANAGED_PROFILE_CREATED)
                    .putExtra(Intent.EXTRA_USER_HANDLE, userInfo.id)
                    .putExtra(
                            DevicePolicyManager.EXTRA_PROVISIONING_LEAVE_ALL_SYSTEM_APPS_ENABLED,
                            provisioningParams.isLeaveAllSystemAppsEnabled())
                    .setPackage(getManagedProvisioningPackage(mContext))
                    .addFlags(Intent.FLAG_RECEIVER_FOREGROUND);
            mContext.sendBroadcastAsUser(intent, UserHandle.SYSTEM);
            return userInfo.getUserHandle();
        } catch (Exception e) {
            DevicePolicyEventLogger
@@ -16328,15 +16319,6 @@ public class DevicePolicyManagerService extends BaseIDevicePolicyManager {
            }
            disallowAddUser();
            final Intent intent = new Intent(DevicePolicyManager.ACTION_PROVISIONED_MANAGED_DEVICE)
                    .putExtra(Intent.EXTRA_USER_HANDLE, caller.getUserId())
                    .putExtra(
                            DevicePolicyManager.EXTRA_PROVISIONING_LEAVE_ALL_SYSTEM_APPS_ENABLED,
                            provisioningParams.isLeaveAllSystemAppsEnabled())
                    .setPackage(getManagedProvisioningPackage(mContext))
                    .addFlags(Intent.FLAG_RECEIVER_FOREGROUND);
            mContext.sendBroadcastAsUser(intent, UserHandle.SYSTEM);
        } catch (Exception e) {
            DevicePolicyEventLogger
                    .createEvent(DevicePolicyEnums.PLATFORM_PROVISIONING_ERROR)