当我点击右侧的索引时,除非我点击最右侧的像素,否则它会激活附件按钮。如何使配件按钮的宽度变小,以便点击不要覆盖索引列表?
func tableView(tableView: UITableView,
accessoryButtonTappedForRowWithIndexPath indexPath: NSIndexPath) {
self.container = self.fetchedResultsController?.objectAtIndexPath(indexPath) as? NSManagedObject
}
也许这是相互矛盾的:
cell.imageView.contentMode = UIViewContentMode.ScaleToFill;
cell.imageView.layer.cornerRadius = 42.5; // 85 x 85
cell.imageView.layer.masksToBounds = true;
cell.imageView.transform = CGAffineTransformMakeScale(0.4, 0.4);
cell.imageView.layer.borderWidth = 3;
cell.imageView.layer.borderColor = UIColor(white:0.2, alpha:0.4).CGColor;