正如我的标题所说,我希望UITableView在用户出现时从左到右滑动第一行ViewController.
在我的ViewController一个UITableView,每行有两个按钮"更多"和"删除"动作.看下面的代码
func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool {
    return true
}
func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) {
    if (editingStyle == UITableViewCellEditingStyle.delete) {
    }
}
func tableView(_ tableView: UITableView, editActionsForRowAt indexPath: IndexPath) -> [UITableViewRowAction]? {
    let deleteButton = UITableViewRowAction(style: .normal, title: "Delete") { action, index in
        // Edit Button Action
    }
    deleteButton.backgroundColor = UIColor.red
    let editButton = UITableViewRowAction(style: .normal, title: "Edit") { action, index …Run Code Online (Sandbox Code Playgroud)