getActiveNotifications always null when using NotificationListenerService

泪湿孤枕 提交于 2019-11-30 16:20:56

After I enable this application in Notification Access section in Settings -> Security.

I can received data from getActiveNotifications now.

Thanks,

Maybe also you need to check if the "extra" exist before that use it. For example: (intent.hasExtra("command") && intent.getStringExtra("command").equals("clearall")). I hope to help you!.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!