![]() I have to push a new view controller hereīut if I want to push the place detail view controller I need to access the controller. Let tapGestureRecognizer = UITapGestureRecognizer(target: self, class PlaceCell: UICollectionViewCell weak var placeName: UILabel! So I have to put the PlaceNameLabel's UITapGestureRecognizer code inside the PlaceCell class. This doesn't matter controller, collectionviews or wherever cell is used, this is independent of where it is used. It has a label which identify the place name ( PlaceNameLabel) and will navigate to place detail when user taps on it. ![]() Let's say I have a custom cell ( PlaceCell) which I'm using in different controllers and collectionviews. ![]() This is a problem that I always stay in dilemma when I creating cells.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |