[macOS] Updates Import/Export of OPML

- Created OPML UTType
- Added OPML as an importable UTI type
- `allowedFileTypes` replaced with `allowed ContentTypes`
- Moved UTType extension to single shared file
- Build flags updated
This commit is contained in:
Stuart Breckenridge
2023-05-31 16:32:51 +08:00
parent e1aa5f8c17
commit abcc836c07
6 changed files with 76 additions and 31 deletions

View File

@@ -75,7 +75,7 @@ import Account
func exportOPML(account: Account) {
let panel = NSSavePanel()
panel.allowedFileTypes = ["opml"]
panel.allowedContentTypes = [.xml]
panel.allowsOtherFileTypes = false
panel.prompt = NSLocalizedString("panel.prompt.export-opml", comment: "Export OPML")
panel.title = NSLocalizedString("panel.title.export-opml", comment: "Export OPML")