[android-developers] Re: How to save state of message queue?

2008-03-28 Thread severian
Thanks hackbod, that clarifies things. But if I understand you correctly, that means that we can't use the Handler/MessageQueue mechanism if we want to make sure we don't lose messages. We instead have to implement our own version that uses persistent storage for the data store. I guess I am sur

[android-developers] How to save state of message queue?

2008-03-27 Thread severian
I'm not sure how to preserve the state of the message queue between instantiations of the application. To take the example of my app, I have a Service that starts a background thread. It creates a Handler for that thread which is subsequently used by Activities to post messages for background pro

[android-developers] Re: Intent Receiver for android.intent.action.INSERT

2008-03-26 Thread severian
Thanks, hackbod, for your comments. I see how this API is satisfactory for the stated purpose of notifying other view elements when they need to re-sync with the ContentProvider. Of course, that is not the only kind of application that cares about changes to content, and I personally wish you guy

[android-developers] Re: Intent Receiver for android.intent.action.INSERT

2008-03-26 Thread severian
The problem is that ContentObserver.onChange() doesn't tell you what changed. So how do you figure it out? Well, as far as I can tell you have to keep your own copy of everything you might care about in the database, and then when you get onChange() you read everything from the ContentProvider and