android8.1 屏蔽系统通知弹窗

该解决办法只是把来通知时下拉的通知框屏蔽掉,

具体通知类容在后台仍然能查看 具体修改如下:

 

--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBar.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBar.java
@@ -1693,8 +1693,9 @@ public class StatusBar extends SystemUI implements DemoMode,
     }

     private void addEntry(Entry shadeEntry) {
-        boolean isHeadsUped = shouldPeek(shadeEntry);
+        boolean isHeadsUped = false;
         if (isHeadsUped) {
             mHeadsUpManager.showNotification(shadeEntry);
             // Mark as seen immediately
             setNotificationShown(shadeEntry.notification);

你可能感兴趣的:(android系统)