ExpandableListView has setOnItemClickListener, which is called for both group and child items.
You can tell groups from children by looking at its id value. However, this UI would look the same as all other expandable list views, but work differently - are you sure you want to do this? -- Kostya 2011/4/5 Carbodrache <[email protected]> > Hello, > > I have an expandableListView with simple textViews, I want to have the > same result on a item (parent or child) click but if I use > ExpandableListView.setOnGroupClickListener() method I can't handle the > expand of the parent node and so can't see children. > > The solution I found is to add an OnClickListener to the group's > textViews, in the BaseExpandableListAdapter.getGroupView(). > > My question is : Is there a better way to have detect on which View > the click is ? An idea I have is to detect the click on the expand > button to expand/collapse the group and use > ExpandableListView.setOnGroupClickListener() on the group row to do > what I want > > Help please ! > > -- > 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 -- 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

