Fix queue toolbar items validation

This commit is contained in:
Damiano Galassi committed 2025-03-13 09:50:35 +01:00
1 parent 7abffdda03
commit f0faeb066a
2 files changed
+7 -2

No files matched your search

+1 -1
View File
@@ -129,7 +129,7 @@ class DocumentToolbarDelegate: NSObject, NSToolbarDelegate {
toolTip: NSLocalizedString("Show the Queue window", comment: "Toolbar"),
image: "ToolbarActionTemplate",
symbolName: "photo.stack",
target: target,
target: nil,
action: #selector(AppDelegate.showQueueWindow(_:)))
}
+6 -1
View File
@@ -227,7 +227,8 @@ final class DocumentWindowController: NSWindowController, TracksViewControllerDe
#selector(iTunesFriendlyTrackGroups(_:)),
#selector(clearTrackNames(_:)),
#selector(prettifyAudioTrackNames(_:)),
#selector(fixAudioFallbacks(_:)):
#selector(fixAudioFallbacks(_:)),
#selector(sendToQueue(_:)):
return true
case #selector(sendToExternalApp(_:)) where mp4.hasFileRepresentation && doc.isDocumentEdited == false:
@@ -288,6 +289,10 @@ final class DocumentWindowController: NSWindowController, TracksViewControllerDe
// MARK: Actions
@IBAction func sendToQueue(_ sender: Any) {
doc.sendToQueue(self)
}
@IBAction func sendToExternalApp(_ sender: Any) {
if let fileURL = doc.fileURL {
_ = sendToFileExternalApp(fileURL: fileURL)