scrollViewDidScroll not executing

天大地大妈咪最大 提交于 2019-12-12 22:17:35

问题


I think have decent experience working with iPhone development. as much I know.. I did set up the delegate.. I have from top to botton UIView --> UIScrollView--> UITextView

I tried everything... to get the event scrollView to fire the scrollViewDidScroll event.

is anything wrong with the structure.. there not much of the code to post here. what I am trying to do is.. do something when UITextView is scrolled.


回答1:


Sorry did not respond... Just wanted to share in case anyone need this... I used delegate methods of parent i.e. UIView for UIScrollView i.e. Child it worked..




回答2:


It's hard to say without some code or a screenshot. Is the scroll view actually scrolling? If you set it up in Interface Builder, did you change the size of the scroll view's contentSize in code so that it can actually scroll? Maybe the text view is eating the scroll events; did you try setting the text view's delegate to see if it's firing a scrollViewDidScroll event?



来源:https://stackoverflow.com/questions/3927509/scrollviewdidscroll-not-executing

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!