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

[Bug] DidDeselect not working #1

Open
thiagobutignon opened this issue Sep 12, 2019 · 1 comment
Open

[Bug] DidDeselect not working #1

thiagobutignon opened this issue Sep 12, 2019 · 1 comment

Comments

@thiagobutignon
Copy link

Hi,

When you click in a cell and click in the same cell to dismiss, it's impossible to pick the this action using DidDeselect or ShouldDidDeselect.

It's possible to pick the event on click to dismiss this in the same cell?

Thanks!

@Quackbarchik
Copy link

Hi,

When you click in a cell and click in the same cell to dismiss, it's impossible to pick the this action using DidDeselect or ShouldDidDeselect.

It's possible to pick the event on click to dismiss this in the same cell?

Thanks!

Hi.

  1. Create delegate for root cell (CB3DSelectCell)
    internal protocol CB3DSelectCellDelegate: class {
        func deselect()
    }

end create instance

    weak var delegate: CB3DSelectCellDelegate?
  1. In function snapshotTapped make a call delegate function
    delegate?.deselect()
  1. In cellForItemAt
    cell.delegate = self
  1. Subscribe to the delegate
    extension CollectionManager: CB3DSelectCellDelegate {
        func deselect() {
            didDeselect?()
        }
    }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants