SuperDizzy / JEEPageControl

A custom pageControl,which implement by Swift
MIT License
24 stars 8 forks source link

pageControl占用了UIScrollView的代理 #3

Open shinancao opened 8 years ago

shinancao commented 8 years ago

在PageControl的内部,将UIScrollView的delegate设置成了PageControl,那么在ViewController中也需要用到该UIScrollView的delegate方法,该如何做呢?

SuperDizzy commented 8 years ago

你可以给PageControl添加一个 delegate 模拟 scrollView 的 delegate,在 scrollView 的 delegate 调用时也去调用这个 delegate,就可以将 scrollView 的代理方法传递出来了