You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

22 lines
687 B

// Copyright © 2015 Abhishek Banthia
import Foundation
class UpcomingEventViewItem: NSCollectionViewItem {
static let reuseIdentifier = NSUserInterfaceItemIdentifier("UpcomingEventViewItem")
@IBOutlet weak var calendarColorView: NSView!
@IBOutlet weak var eventTitleLabel: NSTextField!
@IBOutlet weak var eventSubtitleLabel: NSButton!
func setup(_ title: String, _ subtitle: String, _ color: NSColor) {
calendarColorView.layer?.backgroundColor = color.cgColor
eventTitleLabel.stringValue = title
eventSubtitleLabel.stringValue = subtitle
}
override var acceptsFirstResponder: Bool {
return false
}
}