2012-09-04 30 views
0

我處於tableView編輯模式。我在tableView的左側有一個複選標記。點擊UITableViewCell編輯模式上的複選標記

- (UITableViewCellEditingStyle)tableView:(UITableView *)tableView editingStyleForRowAtIndexPath:(NSIndexPath *)indexPath{ 
return UITableViewCellAccessoryCheckmark; 
} 

didSelectRowAtIndexPath獲取調用每次我在對號挖掘。

當我取消勾選複選標記(即再次點擊單元格)didSelectRowAtIndexPath不是再次調用。

任何人都知道解決這個問題嗎?

也許是每次按下複選標記時被調用的另一種方法?

回答

2

tableview:didSelectRowAtIndexPath:僅在單元格爲時選中。如果您想知道何時取消選擇,請使用:

- (void)tableView:(UITableView *)tableView didDeselectRowAtIndexPath:(NSIndexPath *)indexPath 
+1

這是我需要的!該死。從來不知道這退出。 – Legolas

相關問題