On Fri, Feb 5, 2010 at 8:39 AM, Gustavo <[email protected]> wrote:

> you told me "setOnGroupClickListener" because I can get the
> groupPosition and that's exactly what I need BUT it only works after I
> click on the group since it's inside setOnGroupClickListener where can
> I place the button's onClickListener so that I can get the
> groupPosition?
>

I'm not really sure what you're asking. If you're trying to get the group
position based on the button that was pressed, I guess you could try:
a ) Get the parent of the button which would be the group and get that
view's index in the adapter.
b) Store the group index in the each button's Tag property
c) Store a map of Buttons -> group index that you can index.

If this is not what you mean you'll have to clarify.

-------------------------------------------------------------------------------------------------
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en

Reply via email to