title: drawRect: Not called for an NSView with a CAMetalLayer
body: <p>I have a <em>layer-backed</em> (<strong>not</strong> <em>layer-hosted</em>) subclass of <strong>NSView</strong> called <strong>MetalView</strong>:</p>
  
  <pre><code>import Cocoa
  import Metal
  
  class MetalView: NSView {
  
      // MARK: Properties
  
      var metalLayer: CAMetalLayer {
          return layer as! CAMetalLayer
      }
  
      // MARK: - Overrides
  
      override func awakeFromNib() {
          super.awakeFromNib()
          initialize()
      }
  
      override func drawRect(dirtyRect: NSRect) {
          super.drawRect(dirtyRect)
          render()
      }
  
      override func drawLayer(layer: CALayer, inContext ctx: CGContext) {
          super.drawLayer(layer, inContext: ctx)
          render()
      }
  
      override func displayLayer(layer: CALayer) {
          super.displayLayer(layer)
          render()
      }
  
      override func makeBackingLayer() -&gt; CALayer {
          return CAMetalLayer()
      }
  
      override var wantsUpdateLayer: Bool {
          return false
      }
  
      // MARK: - Initialization
  
      func initialize() {
          // Layer
          wantsLayer = true
          metalLayer.delegate = self
          metalLayer.device = MTLCreateSystemDefaultDevice()
          metalLayer.pixelFormat = .BGRA8Unorm
          metalLayer.framebufferOnly = true
      }
  
      // MARK: - Rendering
  
      func render() {
          // Rendering
          metalLayer.frame = frame
          NSLog("rendering")
      }
  
  }
  </code></pre>
  
  <p>The <strong>render</strong> method is not getting called. I tried setting <strong>wantsUpdateLayer</strong> to <strong>true</strong>. The <strong>render</strong> method gets called with I remove this part:</p>
  
  <pre><code>wantsLayer = true
  metalLayer.delegate = self
  metalLayer.device = MTLCreateSystemDefaultDevice()
  metalLayer.pixelFormat = .BGRA8Unorm
  metalLayer.framebufferOnly = true
  </code></pre>