|
@@ -41,6 +41,7 @@ class KMSectionCellView: NSTableCellView, NibLoadable {
|
|
override func awakeFromNib() {
|
|
override func awakeFromNib() {
|
|
super.awakeFromNib()
|
|
super.awakeFromNib()
|
|
|
|
|
|
|
|
+ self.updateUI()
|
|
self.expandButton.target = self
|
|
self.expandButton.target = self
|
|
self.expandButton.action = #selector(expandAction)
|
|
self.expandButton.action = #selector(expandAction)
|
|
}
|
|
}
|
|
@@ -49,9 +50,7 @@ class KMSectionCellView: NSTableCellView, NibLoadable {
|
|
self.itemClick?(1)
|
|
self.itemClick?(1)
|
|
}
|
|
}
|
|
|
|
|
|
- override func updateLayer() {
|
|
|
|
- super.updateLayer()
|
|
|
|
-
|
|
|
|
|
|
+ func updateUI() {
|
|
self.wantsLayer = true
|
|
self.wantsLayer = true
|
|
if KMAppearance.isDarkMode() {
|
|
if KMAppearance.isDarkMode() {
|
|
self.layer?.backgroundColor = NSColor(hex: "#424345").cgColor
|
|
self.layer?.backgroundColor = NSColor(hex: "#424345").cgColor
|
|
@@ -59,4 +58,10 @@ class KMSectionCellView: NSTableCellView, NibLoadable {
|
|
self.layer?.backgroundColor = NSColor(hex: "#EAECF2").cgColor
|
|
self.layer?.backgroundColor = NSColor(hex: "#EAECF2").cgColor
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ override func updateLayer() {
|
|
|
|
+ super.updateLayer()
|
|
|
|
+
|
|
|
|
+ self.updateUI()
|
|
|
|
+ }
|
|
}
|
|
}
|