Actually, I hadn't. But it doesn't seem to do 'quite' what I had in mind, since I was looking for a button to switch the views. That's when I found out I can do a quick switch from Activity to MapActivity, but the reverse crashes.
If startFlipping() triggers instantly, then I'm fine. If not, the app is going to appear slow, without a low delay, and I'd be forced to play roulette with which view I was in prior to getting the view the user wants. On Nov 19, 4:30 pm, Mark Murphy <[EMAIL PROTECTED]> wrote: > Alvin Yates wrote: > > Quick question: Is there a way to start a new activity and close the > > current one? Basically keep the Activity stack from growing, but my > > main concern is preventing multiple instances of the same Activity > > from spawning. > > Call startActivity() to spawn the new one, then call finish() to close > the old one. However, there may be better ways to skin this proverbial cat. > > > I'm trying to create an app that will allow for changing views from a > > standard Activity layout to a Map Layout, but since forcing the layout > > back and forth crashes the app, it seems to require multiple > > Activities. However, by doing so, hitting back repeatedly would cycle > > between views, not send the user out of the app. > > Have you considered a ViewFlipper? Basically, have both layouts in one > Activity, and toggle between them. While this means your one Activity is > more pudgy than with just the single layout, this is probably less > resource-intensive than killing and starting activities a lot. > > -- > Mark Murphy (a Commons Guy)http://commonsware.com > > Android Training on the Ranch! -- Mar 16-20, > 2009http://www.bignerdranch.com/schedule.shtml --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---

