jessesquires/ReactiveCollectionsKit

Expose `UIScrollViewDelegate` to clients

Closed this issue · 0 comments

There are valid cases to need to implement UIScrollViewDelegate. Unfortunately, UICollectionViewDelegate inherits from UIScrollViewDelegate. (Such a terrible design.) This means clients currently have no way to implement UIScrollViewDelegate methods, because CollectionViewDriver is the collection view's delegate. If clients steal the delegate, then Bad Things™ happen.

Todo:

  • Allow clients to set a weak var scrollViewDelegate: UIScrollViewDelegate? on CollectionViewDriver
  • Implement the UIScrollViewDelegate methods in CollectionViewDriver and forward them to this delegate