I'm interested in this discussion also. I had this exact problem and
put it on hold for a while with a workaround. I decided that I would
probably need a child view that is a superset of all the desired group
views and that I would set the visibility of the child view components
as I determined the group of the child view to be rendered.

I had also been thinking that for the database that represents the
various groups, I would use the Ruby on Rails pattern of combining all
the child objects into a single table, with a group_id, keyed off of
the id of the GroupName.

This would work because the data that I was going to be dealing with
were actually related, in an inheritance sense, so I could get away
with it.

Were my groups to represent biological trees, with wildly different
member components between groups, I'd have to rethink that approach.

On Sep 21, 2:15 am, dashman <erjdri...@gmail.com> wrote:
> thanks for the response.
>
> in my getChildView() method of my adapter, i have:
>
>                 View v;
>             if (convertView == null) {
>                     v = newChildView(isLastChild, parent);
>             } else {
>                     v = convertView;
>             }
>
> 1. i would imagine newChildView would create the default layout - i
> have
> to create the different layout manually?
>
> 2. convertView can be a view with either type - right? how do i know
> what
> type it is.
>
> On Sep 20, 10:02 pm, TreKing <treking...@gmail.com> wrote:
>
>
>
> > On Mon, Sep 20, 2010 at 8:17 PM, dashman <erjdri...@gmail.com> wrote:
> > > is that possible - i.e. a ELV with different layouts for a group view.
>
> > Sure. The View returned for a group (or it's children) is determined by you
> > in the adapter. You can return whatever you want depending on your current
> > needs.
>
> > --------------------------------------------------------------------------- 
> > ----------------------
> > TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago
> > transit tracking app for Android-powered devices

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

Reply via email to