-
Book Overview & Buying
-
Table Of Contents
Creating Dynamic UI with Android Fragments
By :
This chapter discusses the relationship of the lifecycle of fragments to that of activities, and demonstrates the appropriate programming actions at the various points in the lifecycle. The special purpose fragment classes ListFragment and DialogFragment are introduced with coverage of their use and how their behavior in the activity lifecycle differs from that of standard fragments.
The following topics are covered in this chapter:
Fragment setup/display event sequence
Fragment teardown/hide event sequence
Working with the ListFragment class
Working with the DialogFragment class
Interacting with a DialogFragment class as a traditional Dialog class
Wrapping an existing Dialog class in a DialogFragment class
By the end of this chapter, we will be able to coordinate the setup and teardown of fragments within their host activities, and be able to effectively utilize the ListFragment and DialogFragment classes.
Change the font size
Change margin width
Change background colour