func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell
{
var renderWidth:CGFloat = 8
var renderYPosition:CGFloat = 22
let cell = tableView.dequeueReusableCellWithIdentifier("idcell", forIndexPath: indexPath) as! UITableViewCell
var bottomBorder = CALayer()
bottomBorder.backgroundColor = (UIColor(red:1.00, green:0.90, blue:0.00, alpha:1.0).CGColor)
bottomBorder.frame = CGRectMake(0, cell.frame.size.height-1 , cell.frame.size.width+800, 1)//#ffe500
cell.layer.addSublayer(bottomBorder)
cell.layer.removeFromSuperlayer()
}
即使我在addsublayer之后立即删除子层。它仍然出现了。如何删除刚刚添加的图层。