Last active
September 17, 2015 09:04
-
-
Save corosukeK/932b1408e69233b8c713 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
override func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath) { | |
let selectedCell = tableView.cellForRowAtIndexPath(indexPath) | |
tableView.visibleCells.forEach { (cell) -> () in | |
cell.accessoryType = .None | |
} | |
selectedCell?.accessoryType = .Checkmark | |
tableView.deselectRowAtIndexPath(indexPath, animated: true) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment