Hi,

Here is my problem : I have a view containing a listView. And each row
of this listview is composed of a linearLayout, itself composed of
three textview and a gridView. Here is a summary of my layout for one
row :

<LinearLayout
        <TableLayout >
                <TableRow>
                        <TextView > one textview        </TextView>
                        <TextView > two textview        </TextView>
                        <TextView > three textview      </TextView>
                </TableRow>
        </TableLayout>

        <GridView > one gridView </GridView>
</LinearLayout>

I want to perform an action when the user click anywere on an item of
the listview. So I try these two approaches on the listview :
 - myActivity.getListView().setOnTouchListener(new View.OnTouchListener
() {...})
 - myActivity.getListView().setOnItemClickListener(new
AdapterView.OnItemClickListener() { ...})

And here is the trouble :
- when I click on the textview, it nearly works : the touch listener
is called, but not the clicklistener
- when I click on the gridView it doesn't work....the event is just
dispatched to the element of the gridView...

I try :
 myActivity.getListView().setClickable(true);
 myActivity.getListView().setFocusable(true);
 myActivity.getListView().setFocusableInTouchMode(true);
The result is strange...It was not possible anymore to select the
element of my gridView....and it is perfect for my application...but
the listview's listeners are not called when I click on a row...

I try "setEnabled(false)" on the element of the gridView. I try
"setFocusable(false)", etc...and no result...

I try to define a listener for the gridview's item, to check that the
event exists...and there is an event...the listener of the gridview is
called...but is there any way that the parents receive the event to ?

For the touch listener, it seems that there is a problem with the
gridview...any solution ?

Thanks,
I hope it was clear...

-- 
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