Loading services/core/java/com/android/server/om/OverlayManagerService.java +6 −9 Original line number Original line Diff line number Diff line Loading @@ -39,7 +39,6 @@ import android.annotation.NonNull; import android.annotation.Nullable; import android.annotation.Nullable; import android.annotation.UserIdInt; import android.annotation.UserIdInt; import android.app.ActivityManager; import android.app.ActivityManager; import android.app.ActivityManagerInternal; import android.app.IActivityManager; import android.app.IActivityManager; import android.content.BroadcastReceiver; import android.content.BroadcastReceiver; import android.content.Context; import android.content.Context; Loading Loading @@ -1417,18 +1416,16 @@ public final class OverlayManagerService extends SystemService { private static void broadcastActionOverlayChanged(@NonNull final Set<String> targetPackages, private static void broadcastActionOverlayChanged(@NonNull final Set<String> targetPackages, final int userId) { final int userId) { final PackageManagerInternal pmInternal = LocalServices.getService(PackageManagerInternal.class); final ActivityManagerInternal amInternal = LocalServices.getService(ActivityManagerInternal.class); CollectionUtils.forEach(targetPackages, target -> { CollectionUtils.forEach(targetPackages, target -> { final Intent intent = new Intent(ACTION_OVERLAY_CHANGED, final Intent intent = new Intent(ACTION_OVERLAY_CHANGED, Uri.fromParts("package", target, null)); Uri.fromParts("package", target, null)); intent.setFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT); intent.setFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT); final int[] allowList = pmInternal.getVisibilityAllowList(target, userId); try { amInternal.broadcastIntent(intent, null /* resultTo */, null /* requiredPermissions */, ActivityManager.getService().broadcastIntent(null, intent, null, null, 0, null, false /* serialized */, userId, allowList, null /* filterExtrasForReceiver */, null, null, android.app.AppOpsManager.OP_NONE, null, false, false, userId); null /* bOptions */); } catch (RemoteException e) { Slog.e(TAG, "broadcastActionOverlayChanged remote exception", e); } }); }); } } Loading Loading
services/core/java/com/android/server/om/OverlayManagerService.java +6 −9 Original line number Original line Diff line number Diff line Loading @@ -39,7 +39,6 @@ import android.annotation.NonNull; import android.annotation.Nullable; import android.annotation.Nullable; import android.annotation.UserIdInt; import android.annotation.UserIdInt; import android.app.ActivityManager; import android.app.ActivityManager; import android.app.ActivityManagerInternal; import android.app.IActivityManager; import android.app.IActivityManager; import android.content.BroadcastReceiver; import android.content.BroadcastReceiver; import android.content.Context; import android.content.Context; Loading Loading @@ -1417,18 +1416,16 @@ public final class OverlayManagerService extends SystemService { private static void broadcastActionOverlayChanged(@NonNull final Set<String> targetPackages, private static void broadcastActionOverlayChanged(@NonNull final Set<String> targetPackages, final int userId) { final int userId) { final PackageManagerInternal pmInternal = LocalServices.getService(PackageManagerInternal.class); final ActivityManagerInternal amInternal = LocalServices.getService(ActivityManagerInternal.class); CollectionUtils.forEach(targetPackages, target -> { CollectionUtils.forEach(targetPackages, target -> { final Intent intent = new Intent(ACTION_OVERLAY_CHANGED, final Intent intent = new Intent(ACTION_OVERLAY_CHANGED, Uri.fromParts("package", target, null)); Uri.fromParts("package", target, null)); intent.setFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT); intent.setFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT); final int[] allowList = pmInternal.getVisibilityAllowList(target, userId); try { amInternal.broadcastIntent(intent, null /* resultTo */, null /* requiredPermissions */, ActivityManager.getService().broadcastIntent(null, intent, null, null, 0, null, false /* serialized */, userId, allowList, null /* filterExtrasForReceiver */, null, null, android.app.AppOpsManager.OP_NONE, null, false, false, userId); null /* bOptions */); } catch (RemoteException e) { Slog.e(TAG, "broadcastActionOverlayChanged remote exception", e); } }); }); } } Loading