I have a custom view (A) that contains a ViewFlipper, which flips between three custom views (B1, B2, B3). Each B view is a LinearLayout containing a TextView and a GridView. The problem is that i need touch events on the GridView to be handled by the A view. This is so that fling events on any GridView get handled by the ViewFlipper.
It seems simple enough... just make the touch listeners for the B views and GridViews return false, right? Wrong. It doesnt work. The B.onTouchEvent() is never called by touch events on a GridView and neither is ViewFlipper.onTouchEvent(). Strange but true, and I have the Logs to prove it. I tried passing an instance of the parent A view to each of the B views so that when a touch event happens I can dispatch all touch events to the parent A view. The result...an infinite loop and stack overflow because the A view first passes the event back to its children. How do I get a view to handle all of its touch events without passing those events to its children? In truth, i dont need children to respond to ANY touch events at all. Ideally, I would like ALL touch events to be handled by the A view and never by any of its children. Is there a way to force this? Thanks. -- 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