0
我想添加複選標記到我的UItableview單元格。我想對號對這樣的形象左旁顯示像圓圈按鈕:UITableView左邊的複選標記按鈕 - 斯威夫特
我無法獲得在左邊的選中標記我的代碼,而是我一直在右側獲得複選標記是僅在點擊時顯示。這是我現在的代碼:
override func tableView(tableView: UITableView, didDeselectRowAtIndexPath indexPath: NSIndexPath) {
if let cell = tableView.cellForRowAtIndexPath(indexPath) {
cell.accessoryType = .None
}
}
override func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath) {
if let cell = tableView.cellForRowAtIndexPath(indexPath) {
cell.accessoryType = .Checkmark
}
}
任何想法,我怎麼能得到複選標記顯示在左邊像圖像?
希望你能把它轉換成swift。:)它只是一種語言。 –
elk_cloner它看起來像項目已經在迅速:) – ajayb
哦!我做到了,我忘了。 :) –