I am developing a map program where I want a user to click on a button and then more information will pop up with information or a dialer. I know I can just start an activity-which is the quickest way it seems. However, should it be a different class-an Intent or subclass of Activity. I want to be able to go back to the main program easily-if seems I can't do that after an activity as easily as I hoped.
Thanks for any help!
posted 8 years ago
You'll create a subclass of Activity, and create your new user interface screen there.
To cause the Activity to start you'll create an instance of Intent, filling it in with any parameters. Then you'll either tell Android the exact class to start (if you know it), or ask Android to search for somebody that can fulfill the request (if you don't know it or you want to let other developers replace the Activity that will be called).
For more info see these book sections:
Section 2.3, Building Blocks
Section 3.5, Implementing an About Box
Section 4.2, Starting the Game