Question: Write an Android Application that demonstrates the activity life cycle and fragments. The main activity should have two fragments. The top fragment contains a list
Write an Android Application that demonstrates the activity life cycle and fragments. The main activity should have two fragments. The top fragment contains a list view control whose items are the names of two other activities, AIActivity and VRActivity. The bottom fragment uses a text view control to display the list of life cycle methods that take place when the main activity starts.
Use Toast class methods to display a quick message in fragments onCreateView and onStart methods.
The AIActivity and ARActivity should each have a TextView control to display messages when onCreate, onStart, onResume, and onPause methods are executed.
Declare the String resources in strings.xml filetable::gradA::LabExLabExtableLife Cycle Methods DemonstrationAlActivitytableAlActivity:onCreate executedVRActivityonStart executedtableMain Activity:onCreate executedonStart executed
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
