スワイプメニューを閉じたい
スワイプでメニュー
を出し、Doneアクションでチェックマークをつけて、メニュー
を閉じたいのですが、どうすればいいですか?
override func tableView(_ tableView: UITableView, leadingSwipeActionsConfigurationForRowAt indexPath: IndexPath) -> UISwipeActionsConfiguration? {
let action = UIContextualAction(style: UIContextualAction.Style.normal, title: "Done") { (action, view, completionHandler) in
let cell = tableView.cellForRow(at:indexPath)
cell?.accessoryType = UITableViewCell.AccessoryType.checkmark
}
return UISwipeActionsConfiguration(actions: [action])
}
