본문 바로가기

iOS

[Swift] contentView

반응형

Declaration

var contentView: UIView { get }

Discussion

The content view of a UITableViewCell object is the default superview for content that the cell displays. If you want to customize cells by simply adding additional views, you should add them to the content view so they position appropriately as the cell transitions in to and out of editing mode.

 

셀에다가 무언가를 구현할 때, 최상단부터 최하단까지 잘 이어줘야함...

안그러면.. 버튼이 동작안할 때가 있음.

contentView.addSubview(containerView)

 

'iOS' 카테고리의 다른 글

[Swift] dequeueReusableCell  (0) 2022.02.10
[Swift] 함수(Function)?  (0) 2022.01.27
[Swift] isUserInteractionEnabled  (0) 2022.01.24
[Swift] NotificationCenter  (0) 2022.01.12
[Swift] Substring  (0) 2022.01.12