I subclassed an NSCollectionViewItem and want to modify the layer of its view, but I can't get it to work.
override func awakeFromNib() {
self.view.layerContentsRedrawPolicy = NSViewLayerContentsRedrawPolicy.OnSetNeedsDisplay
self.view.layer!.backgroundColor = NSColor.whiteColor().CGColor
self.view.layer!.borderColor = NSColor.blackColor().CGColor
self.view.layer!.borderWidth = 3
self.view.updateLayer()
}
I activated core layer animation in IB of every single view in my project, but still no change. How can I make changes to the views layer?