Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When using UIScrollViewDelegateProxy and UICollectionViewDelegateProxy, one is ignored #61

Open
itsol-ka opened this issue Oct 12, 2021 · 1 comment
Labels
bug Something isn't working

Comments

@itsol-ka
Copy link
Contributor

Describe the bug
When using UIScrollViewDelegateProxy and UICollectionViewDelegateProxy, one is ignored

code

let collectionView = UICollectionView(frame: .zero, collectionViewLayout: layout)
self.collectionView.didSelectItemPublisher.sink { _ in
    print("not called")
}
.store(in: &self.cancellableSet)

self.collectionView.didEndDraggingPublisher.sink { _ in
    print("called")
}
.store(in: &self.cancellableSet)
@itsol-ka itsol-ka added the bug Something isn't working label Oct 12, 2021
@toastersocks
Copy link

I'm running into this exact same thing except with UITableView instead of UICollectionView. I'm subscribed to the willBeginDraggingPublisher and didScrollPublisher of the table view, and also subscribed to the didSelectRowPublisher, and only the didSelectRowPublisher is firing. I previously also had an additional didSelectRowPublisher that was ignored. It seems that all publisher subscriptions but one are lost when we have multiple subscriptions on UIScrollView/UI(Table/Collection)View.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants