feat: add favorites with match-quality-aware ranking
This commit is contained in:
@@ -591,6 +591,12 @@ final class LauncherWindowController: NSWindowController, NSWindowDelegate, NSSe
|
||||
(window as? LauncherPanel)?.resetNumberHints()
|
||||
let application = results[tableView.selectedRow]
|
||||
actions.open = { [weak self] in self?.openApplication(application) }
|
||||
actions.isFavorite = history.isFavorite(application)
|
||||
actions.toggleFavorite = { [weak self] in
|
||||
guard let self else { return }
|
||||
self.history.toggleFavorite(application)
|
||||
self.updateResults(preservingSelection: true)
|
||||
}
|
||||
actions.showInFinder = { [weak self] in
|
||||
self?.dismiss(restoringFocus: false)
|
||||
NSWorkspace.shared.activateFileViewerSelecting([application.url])
|
||||
|
||||
Reference in New Issue
Block a user