Good morning,

I am trying to write a small book catalogue application, and I would
like to use an expandable list adapter for the main display. My aim is
to have the parent showing a list of authors and, once opened, the
child should display a list of book titles and thumbnails.

I have managed to display the text fields using a
SimpleExpandableListAdapter, however I cannot display the thumbnails.
In fact the API (http://developer.android.com/reference/android/widget/
SimpleExpandableListAdapter.html) states
"childTo        ... These should all be TextViews"

Does anyone know how to use TextViews and ImageViews in a single
Childrow. The layout of the child rows looks like.

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/
android"
    android:orientation="horizontal"
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
    android:padding="10dp" >
        <ImageView android:id="@+id/row_img"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
                android:layout_weight="1"
        />
        <TextView android:id="@+id/row_title"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:paddingLeft="10dp"
                />
</LinearLayout>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

To unsubscribe, reply using "remove me" as the subject.

Reply via email to