简体   繁体   中英

UITableView inside UIScrollView not receiving touch at first time

I am having an issue with a UITableView inside a UIScrollView. When I scroll the external scrollView, the table does not receive the willSelect/didSelect event on the first touch, but it does on the second one. Also having same problem with UIButton which is inside the scrollview.

IMPORTANT You should not embed UIWebView or UITableView objects in UIScrollView objects. If you do so, unexpected behavior can result because touch events for the two objects can be mixed up and wrongly handled.

.

I am having lots of data to display on screen. I have added three views inside main scroll (Header,body and footer).Inside body view I have display some data in tableview. – Parvezkhan 2 mins ago

TableViews provide views for Headers & Footers already.So no need to do custom implementation.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM