9.14 Wrap-Up
In this chapter, you created an Address Book app for adding, viewing, editing and deleting contact information that’s stored in a SQLite database.
You used one activity to host all of the app’s Fragment
s. On a phone-sized device, you displayed one Fragment
at a time. On a tablet, the activity displayed the Fragment
containing the contact list, and you replaced that with Fragment
s for viewing, adding and editing contacts as necessary. You used the FragmentManager
and FragmentTransaction
s to dynamically display Fragment
s. You used Android’s Fragment
back stack to provide automatic support for Android’s back button. To communicate data between Fragment
s and the host activity, you defined in each Fragment
subclass a nested interface ...
Get Android How to Program, 3/e now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.