Is there a way to detect a change to the contacts database?
I have a flow that shows a list of contacts with mobile numbers, but it takes 30 seconds to run the load portion. I want to cache the list, and reload only when needed.
Detect change in contacts?
Moderator: Martin
Re: Detect change in contacts?
So far I can't find the broadcast intent after contact has been changed. But at least at the logcat, there are some lines indicating the contact has been changed. It is still not a good solution to log all the time just for contact.
How often do you change the contact info? And how critical it is to be updated to the most recent ones? Maybe just set a interval to reload the contact everyday. Or you can use app task ended for the contact and add a prompt whether you want to reload the list.
How often do you change the contact info? And how critical it is to be updated to the most recent ones? Maybe just set a interval to reload the contact everyday. Or you can use app task ended for the contact and add a prompt whether you want to reload the list.
Index of Automagic useful thread List of my other useful posts (and others')
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.
Re: Detect change in contacts?
Found it... Content provider change. Luckily it was one of the pre-fill options.
Re: Detect change in contacts?
Oh yeah. I missed it. I almost never use it.
Index of Automagic useful thread List of my other useful posts (and others')
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.