March 2013
Beginner to intermediate
580 pages
16h 11m
English
In this chapter, you will capture an image from the camera’s preview and save it as a JPEG on the filesystem. Then you will associate that JPEG with a Crime and display it in CrimeFragment’s view. You will also offer the user the option to view a larger version of the image in a DialogFragment.
Figure 20.1 Crime photo thumbnail and larger-size images

First, you are going to update CrimeCameraFragment’s layout to include a progress indicator. Sometimes the picture-taking process can take a while, and you do not want users getting antsy.
In layout/fragment_crime_camera.xml, add the ...
Read now
Unlock full access