Our application (sandboxed, on the mac) sends Apple Events to itself for being recordable in Script Editor.
Alas, I just noted that this feature stopped working, i.e. at least under macOS 12.4 Script Editor does not see what our application does. I am not sure when (i.e. under what macOS) recordability stopped working, but it is gone on 12.4.
We have tried, (for testing), to set the sandbox exception com.apple.security.temporary-exception.apple-events to true, but it makes no difference.
I know that Apple Script in general, and recordability in particular, are badly out of fashion these days, so we are considering dropping recordability anyway. But if there's an easy way to keep it working, I'd be interested.
Thanks for any advice in advance
Post
Replies
Boosts
Views
Activity
Our app exports a number of file types in info.plist. For each of these file types, we export various possible file name extensions. For example, for one of our file types, we specify the possible extensions ".data", ".fitdat", and ".profitdata".
In the settings of our app, we allow the user to select their preferred extension to be used, i.e. the extension to be used when, e.g., saving a document with "Save As..." panel without explicitly specifying the extension.
For this, we override NSDocument's fileNameExtensionForType:saveOperation to return the presently preferred extension.
This has stopped working, probably starting from macOS 14. If the user does not specify the extension in the NSSavePanel, it's always the first extension (".data") that gets added to the file name.
I guess it's a consequence of the introduction of UTType, which has its own preferredFilenameExtension, which in turn probably just grabs the first extension we specify in our info.plist
Any advice how to resolve this? Is there any way to override NSSavePanel's selection of extension if the user does not specify one?
Thanks for any advice in advance
Kurt