ASH84

Software Engineer/Developer, co-founder of Payhere. Ex-Banksalad. Intereseted in iteroperability, bootstrap company, writting.

(iOS) tableViewCell avoid select event

created:2013-08-08
updated:2015-07-03
edit

touch 이벤트를 기본적으로 TableViewCell  을 customize 해서 사용할때 받게 되는데, TableViewCell 내 버튼같은 컨트롤들이 의도하지 않게 이벤트에 의해서 선택이 되어지는 문제가 있다. 즉, cell 자체의 touch 이벤트가 전달되는 것인데, 의도하지 않는 문제를 일으킬수 있다. 아래처럼 설정을 하면 선택을 해도 반응되지 않는다. 


(How can I disable the UITableView selection highlighting?)

[cell setSelectionStyle:UITableViewCellSelectionStyleNone];

#dev  #IOS  #tableViewCell