I want to know the is there any event into Android which fires on "Android standard browser/Default browser" URL change ?(Not on WebView from my application).
When I load some site into Default browser say : example.com and after that I navigate to the other page(done by User interactions e.g. click etc) like : example.com/page1 Then is there any event fires ? So that I can use that event to do my task.
My solution : (I have not tried this)
- Start background service to watch for default browser is opened?
- If the user enters any url, save this to app memory(may be shared preferences).
- After some time interval again check the url and compare with the previous saved url
- If it does not matches call my method to do task. And update current url into app memory
Instead of doing this is their any events / broadcasts are provided ?
Aucun commentaire:
Enregistrer un commentaire