如何在Android中获取有关浏览器下载完成的通知(广播,意图) [英] how to get notification (broadcast, intent) on browser download completion in android
问题描述
在用户从网络浏览器和其他应用启动的下载完成后,如何通知(通过某种广播或意图)? (例如电子邮件客户端,蓝牙等)。
我需要这个,因为我想对用户下载的每个新文件执行一些操作。
在我看来,这个<某些杀毒应用可能会执行类似的操作。
我尝试使用将Intent过滤器设置为DownloadManager.ACTION_DOWNLOAD_COMPLETE动作的广播接收器,但是这样,我仅收到有关我的下载内容的通知自己的应用。
how to be notified (via some broadcast or intent) on a completion of a download initiated by user from web browser and other apps? (like email client, bluetooth, etc).
I need this as I want to perform some action on each newly file downloaded by the user.
It seems to me that this is possible as some antivirus apps do similar things.
I tried to use broadcast receiver with intent filter set to DownloadManager.ACTION_DOWNLOAD_COMPLETE action, but this way I get notified only about downloads from my own app.
谢谢!
推荐答案
是有没有一种方法(通过某种广播或意图)在用户从网络浏览器和其他应用程序启动的下载完成时得到通知? (例如电子邮件客户端,蓝牙等)。
Is there a way to be notified (via some broadcast or intent) on a completion of a download initiated by user from web browser and other apps? (like email client, bluetooth, etc).
幸运的是,出于明显的隐私和安全性原因。
Fortunately, no, for obvious privacy and security reasons.
这篇关于如何在Android中获取有关浏览器下载完成的通知(广播,意图)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!