cost 53 ms
如何通过单击通知中的操作按钮执行自定义任务? - How to perform a custom task from a action button click in notification?

我的应用程序中有一个通知,我想在单击通知中的操作时执行自定义任务。 我这样做是为了添加一个动作:timerNotificationBuilder.addAction(0, "STOP", null /*What to add here ?*/ ); 但是,我想阻止处理程序在单击此操作时运行。 我 ...

关于 android 12 点击操作按钮时如何关闭通知抽屉 - on android 12 how to close the notification drawer when tap on the action button

当点击通知的操作按钮时,如果它在服务中处理,则通知抽屉可以关闭 但是从 android 12 开始,它已被弃用并且无法关闭通知抽屉。 这是在一个没有积极的无障碍服务的图书馆里。 点击通知的操作按钮时如何关闭通知抽屉? ...


排序:
质量:
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM