티스토리 뷰
class CommentTableViewCell: UITableViewCell {
@IBOutlet var senderLabel: UILabel!
@IBOutlet var timeLabel: UILabel!
@IBOutlet var bodyLabel: UILabel!
override func awakeFromNib() {
super.awakeFromNib()
// Initialization code
let longPressRecognizer = UILongPressGestureRecognizer(target: self, action: #selector(longPressed))
self.contentView.addGestureRecognizer(longPressRecognizer)
}
@objc func longPressed(sender: UILongPressGestureRecognizer) {
print("longpressed")
}
}
'macOS, iOS' 카테고리의 다른 글
[iOS] JSON 형식의 푸시 처리하기 (0) | 2020.07.31 |
---|---|
[iOS] Alamofire - 'there is no such file' 문제 (1) | 2020.07.19 |
[iOS] DateFormatter이용해서 포맷팅하기 (0) | 2020.07.15 |
[iOS] Xcode 코드블록 접는 단축키 (0) | 2020.07.14 |
[iOS] stackview 중간에 넣기, stackview에서 빼기 (0) | 2020.07.14 |