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

Commit e7a835bc authored by John Spurlock's avatar John Spurlock
Browse files

NoMan: Specify all users for noman broadcasts.

Change-Id: I347bc25b09506dd5fd695e68f23e9654bab8103c
parent cf304fb3
Loading
Loading
Loading
Loading
+6 −7
Original line number Diff line number Diff line
@@ -908,11 +908,6 @@ public class NotificationManagerService extends SystemService {
            void onPolicyChanged() {
                sendRegisteredOnlyBroadcast(NotificationManager.ACTION_NOTIFICATION_POLICY_CHANGED);
            }

            private void sendRegisteredOnlyBroadcast(String action) {
                getContext().sendBroadcast(new Intent(action)
                        .addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY));
            }
        });
        final File systemDir = new File(Environment.getDataDirectory(), "system");
        mPolicyFile = new AtomicFile(new File(systemDir, "notification_policy.xml"));
@@ -995,6 +990,11 @@ public class NotificationManagerService extends SystemService {
        publishLocalService(NotificationManagerInternal.class, mInternalService);
    }

    private void sendRegisteredOnlyBroadcast(String action) {
        getContext().sendBroadcastAsUser(new Intent(action)
                .addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY), UserHandle.ALL, null);
    }

    /**
     * Read the old XML-based app block database and import those blockages into the AppOps system.
     */
@@ -1061,8 +1061,7 @@ public class NotificationManagerService extends SystemService {
        ZenLog.traceEffectsSuppressorChanged(mEffectsSuppressor, suppressor);
        mEffectsSuppressor = suppressor;
        mZenModeHelper.setEffectsSuppressed(suppressor != null);
        getContext().sendBroadcast(new Intent(NotificationManager.ACTION_EFFECTS_SUPPRESSOR_CHANGED)
                .addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY));
        sendRegisteredOnlyBroadcast(NotificationManager.ACTION_EFFECTS_SUPPRESSOR_CHANGED);
    }

    private void updateInterruptionFilterLocked() {