If my NSDocument subclass opens a file of a certain type, and then I do a Save 
As (option click the File menu), choose a new name and CHANGE THE EXTENSION, 
shouldn't the document be given the new typeName in -fileWrapperOfType:error: ?

I'm finding that it is passed the original typeName, so the file gets saved 
using the data format of the original file, but end up on disk with the 
extension that I gave it in the Save dialog. The mismatch between the data 
content/format and the extension then confuses NSDocument on subsequent 
attempts to open the file, so it reports that the document cannot be opened.

One of two things seems wrong: either a) the Save As dialog should not permit 
the extension to be changed, or ) the document should be being passed the 
typeName corresponding to the extension I entered. Or is there a step I'm 
missing somewhere that my document subclass should be doing to allow the 
extension to be changed?

--Graham



_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to