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

Commit 49d1a012 authored by Prameet Shah's avatar Prameet Shah
Browse files

Notify AppOps when notifications are [un]blocked for an app.

Bug: crbug.com/934581
Test: atest NotificationManagerServiceTest NotificationManagerTest
Test: Verified that blocked apps stay blocked on Android on ChromeOS.
Change-Id: Ibb57d295a1c4345d0acc514cbfe9994f8184cc9d
parent fc97abca
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -3084,6 +3084,8 @@ public class NotificationManagerService extends SystemService {
                        UserHandle.getUserId(uid), REASON_PACKAGE_BANNED, null);
            }

            mAppOps.setMode(AppOpsManager.OP_POST_NOTIFICATION, uid, pkg,
                    enabled ? AppOpsManager.MODE_ALLOWED : AppOpsManager.MODE_IGNORED);
            try {
                getContext().sendBroadcastAsUser(
                        new Intent(ACTION_APP_BLOCK_STATE_CHANGED)