On Wed, Sep 8, 2010 at 3:44 PM, OldSkoolMark <[email protected]> wrote: > Alternative design approaches would also be greatly appreciated.
Step #1: Refactor such that your UI initialization is not in onCreate(), but is in some other private method (referred to here as setupViews()). Step #2: In onResume(), on a change in layout, call setupViews(). Step #3: There is no step #3. In other words, why destroy and recreate the activity just to load in a different layout? Heck, developers grumble constantly about Android doing that by default for orientation changes... -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android Training in London: http://skillsmatter.com/go/os-mobile-server -- 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

