July 2015
Beginner to intermediate
600 pages
18h 59m
English
Figure 8.1 shows what CrimeFragment’s view will look like by the end of this chapter.
Figure 8.1 CriminalIntent, episode 2
To get this on screen, you are going to add four widgets to CrimeFragment’s layout: two TextView widgets, a Button, and a CheckBox.
Open fragment_crime.xml and make the changes shown in Listing 8.3. You may get errors from missing string resources; you will create them in a moment.
Listing 8.3 Adding new widgets (fragment_crime.xml)
<?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" ...
Read now
Unlock full access