i am using a uiview parent view….overidded touch began and touch ended methods…
when i added a UIButton as a subview in the view and touch on the button touchdown event is detected and associated method is called …but touchbegan method that was over ridden is not called…
what i want is when i touch the button the method associated with the touchdown event and touchBegan method of uiview both be called simultaneously…UIbutton is not passing the touch to its superview i.e. uiview…..?
Any idea how to do that ?
Thanks
I’m not sure exactly how to call two
touchesBeganevents simultaneously on two different views, but you probably want to override thehitTest:withEvent:method ofUIView. This will allow you to catch a touch event on the view underneath theUIButtonbefore it gets to the button (hitTests work from thewindowupwards to the foremost view).Maybe this can help…
EDIT:
Just a guess but you could try: