In my application onCreate method reads some files, creates a bunch of objects (Model) and then creates visual layout. When an orientation gets changed it reads files again. But they are the same. There is no need to read them again. Only visual layout needs to be recalculated. Is there a way to avoid this extra job?
Thank you, Andrey On Dec 15, 12:26 pm, Mark Murphy <mmur...@commonsware.com> wrote: > steff wrote: > > But my problem is this (at this point my misunderstanding kicks in): > > whenever I rotate the device the onCreate(), onStart() etc. methods > > are called, causing my app to act as if it just started. > > Correct. By default, on an orientation change, Android destroys and > recreates your activity, to map in the appropriate layout resources and > such. > > -- > Mark Murphy (a Commons > Guy)http://commonsware.com|http://twitter.com/commonsguy > > _Android Programming Tutorials_ Version 1.0 Available! -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en