开发者

Check when user has launched android browser

开发者 https://www.devze.com 2023-02-11 00:57 出处:网络
I am currently developing an Android app where I need to do so开发者_如何学编程me action when the browser is launched.

I am currently developing an Android app where I need to do so开发者_如何学编程me action when the browser is launched.

What I want is that when the user launches the android browser on their phone my App creates a notification to allow them to launch my app.

How can I check to see if the browser has been opened. I assume I would need to have some sort of background service.

Thanks for the help


There are no broadcasts that are sent out to inform you of other apps starting and stopping. Mostly, this is for privacy reasons, as I understand it.

You are welcome to talk to alternative browser makers, particularly open source ones, to see if they have any sort of architecture for extending their browsers with features such as you wish to implement.


you can do it by keeping a watch over logcat

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号