【发布时间】:2018-01-31 22:15:46
【问题描述】:
我正在开发一个应用程序,我正在使用一些 tableView 单元格。我正在对单元格执行拖放操作,我想在目标位置删除一个单元格。我正在成功地做到这一点。但在删除该单元格之前,我想为该单元格设置动画。我怎样才能做到这一点。以下是我执行此操作的方法。
override func tableView(_ tableView: UITableView, moveRowAt sourceIndexPath: IndexPath, to destinationIndexPath: IndexPath) {
let movedCell = self.colorArray[destinationIndexPath.row]
self.colorArray.remove(at: destinationIndexPath.row)
self.tableView.reloadData()
}
我想在那个movedCell上执行一些动画。 我该怎么做?
【问题讨论】: