Time for action - creating the ListItemSelectionActivity
This is a fairly large and somewhat complex example to work through, so I'll break it into bite size chunks, each with a goal. The first thing we want is an
Acitivity class with a nice looking layout. The layout we'll build is an
EditText above a
ListView, each one with an ID that can be used by the
- Create a new project to contain your
android create project -n Selector -p Selector -k com.packtpub.selector -a ListItemSelectionActivity -t 3
- Open the
res/layout/main.xmlfile in an editor or IDE.
- Remove any of the default layout code.
- Ensure that the root element is a
LinearLayoutconsuming the available screen space in the
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" ...