Open and edit Matroska files in place, including track removal
.mkv/.mka/.mks now open directly into a tags-only document instead of forcing the convert-import sheet: - Metadata, cover art, and the four per-track fields Matroska stores (name, language, enabled, subtitle forced) save back into the same file via MP42MkvTagWriter; MP4-only properties stay read-only. - Real tracks can be deleted and Save-As is enabled; both go through MP42MkvRemuxer's stream-copy rebuild (Document keeps an importer-order track snapshot and pairs TrackEntry elements by object identity). Destinations must stay .mkv/.mka/.mks. - Info.plist: the Matroska document type becomes Editor so NSDocument offers .mkv Save-As instead of defaulting to the MP4 type. - Delete on MKV docs skips organizeAlternateGroups/ inferMediaCharacteristics because they reorder the model, which the TrackEntry pairing depends on; chapter rows stay undeletable. Bumps MP42Foundation for the Matroska tagging/remux support. Co-Authored-By: Claude Code <noreply@anthropic.com>
This commit is contained in:
1 parent
0c3d7de364
commit
eb386a52c3
14 files changed
+540
-32
No files matched your search
@@ -76,7 +76,11 @@ final class ChapterViewController : PropertyView, NSTableViewDataSource, NSTable
|
||||
}
|
||||
|
||||
func tableViewSelectionDidChange(_ notification: Notification) {
|
||||
removeChapter.isEnabled = tableView.selectedRow != -1 ? true : false
|
||||
removeChapter.isEnabled = tableView.selectedRow != -1 && isReadOnly == false
|
||||
}
|
||||
|
||||
func tableView(_ tableView: NSTableView, shouldEdit tableColumn: NSTableColumn?, row: Int) -> Bool {
|
||||
return isReadOnly == false
|
||||
}
|
||||
|
||||
@IBAction func setChapterTitle(_ sender: NSTextField) {
|
||||
@@ -101,12 +105,14 @@ final class ChapterViewController : PropertyView, NSTableViewDataSource, NSTable
|
||||
}
|
||||
|
||||
@IBAction func doubleClickAction(_ sender: NSTableView) {
|
||||
guard isReadOnly == false else { return }
|
||||
if sender.clickedRow > -1 && sender.clickedColumn > -1 {
|
||||
sender.editColumn(sender.clickedColumn, row: sender.clickedRow, with: nil, select: true)
|
||||
}
|
||||
}
|
||||
|
||||
func deleteSelection(in tableview: NSTableView) {
|
||||
guard isReadOnly == false else { return }
|
||||
let indexes = tableView.selectedRowIndexes
|
||||
if indexes.isEmpty == false {
|
||||
track.removeChapters(at: indexes)
|
||||
|
||||
Reference in new issue
Block a user