> Again I am confused a little. If I can show a different layout calling > setContentLayout, please anybody can give me an example of a > compelling situation where my app would need more than one activity ?
Here are a starting set of arguments, and I am sure there are more to be made: 1. Doing everything inside of one activity may cause garbage collection issues. Activities are specifically designed to be "disposable". 2. Doing everything inside of one activity means either the user cannot use the BACK button to navigate, or you have to do that yourself. For example, imagine a Web browser where the BACK button closed up the browser window, or where each Web site had to maintain its own "browser history" for each user. 3. Handling screen rotation via onSaveInstanceState() or the like becomes proportionally more difficult as you add "screens" to an existing activity, rather than have them as independent activities. 4. Some applications will want multiple activities as multiple entry points into the application itself (e.g., main activity versus an app widget configuration activity). -- Mark Murphy (a Commons Guy) http://commonsware.com Android App Developer Books: http://commonsware.com/books.html -- 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

