|
@@ -126,6 +126,11 @@ class KMHomeHistoryCollectionItem: NSCollectionViewItem {
|
|
|
self.showImageView.border(NSColor.clear, 1, 4)
|
|
|
self.verticalTitleLabel.backgroundColor(NSColor.clear)
|
|
|
self.verticalTitleLabel.textColor = KMAppearance.Layout.h0Color()
|
|
|
+
|
|
|
+ let menu = NSMenu(title: "")
|
|
|
+ menu.addItem(NSMenuItem(title: NSLocalizedString("Show in Finder", comment: ""), action: #selector(showPathButtonAction), keyEquivalent: ""))
|
|
|
+ menu.addItem(NSMenuItem(title: NSLocalizedString("Remove from Recents", comment: ""), action: #selector(removePathButtonAction), keyEquivalent: ""))
|
|
|
+ self.view.menu = menu
|
|
|
}
|
|
|
|
|
|
func reloadData() {
|
|
@@ -134,14 +139,6 @@ class KMHomeHistoryCollectionItem: NSCollectionViewItem {
|
|
|
self.updateTypeData()
|
|
|
self.updateFilesData()
|
|
|
}
|
|
|
-
|
|
|
- override func rightMouseDown(with event: NSEvent) {
|
|
|
- let point = self.view.convert(event.locationInWindow, from: nil)
|
|
|
- let menu = NSMenu(title: "")
|
|
|
- menu.addItem(NSMenuItem(title: NSLocalizedString("Show in Finder", comment: ""), action: #selector(showPathButtonAction), keyEquivalent: ""))
|
|
|
- menu.addItem(NSMenuItem(title: NSLocalizedString("Remove from Recents", comment: ""), action: #selector(removePathButtonAction), keyEquivalent: ""))
|
|
|
- menu.popUp(positioning: nil, at: point, in: self.view)
|
|
|
- }
|
|
|
}
|
|
|
|
|
|
extension KMHomeHistoryCollectionItem {
|