Android doesn't do anything to stop your code from working. As you seem to have already said, it is just doing standard serialization as here:
http://android.git.kernel.org/?p=platform/frameworks/base.git;a=blob;f=core/java/android/os/Parcel.java;h=31f87198878aa4ac6c1dd3f8be6e151c1d1c89d8;hb=HEAD#l1154 Note onRetainNonConfigurationInstance is NOT a solution, because in the case where your app goes to the background it still needs to place its UI state in onSaveInstanceState() so it can be restored later if the process is killed. Anything you only put in onRetainnonConfigurationInstance() will be lost, fairly randomly as far as the user is concerned. On Sun, Jun 5, 2011 at 11:49 AM, Emanuel Moecklin <[email protected]>wrote: > Hi Mark > > The serialization code works because my workaround I mentioned in my > previous post works ("write everything into a byte[] using > ObjectOutputStream.writeObject() on top of a ByteArrayOutputStream and then > put the byte[] into the Bundle"). > > I tested your onRetainNonConfigurationInstance/ > getLastNonConfigurationInstance suggestion and that's exactly what I was > looking for! Thanks. > > Remains the question why Android doesn't call through to writeObject? Maybe > Dianne can answer that question? > > Best Regards > Emanuel Moecklin > 1gravity LLC > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en > -- Dianne Hackborn Android framework engineer [email protected] Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

