Re: Saving while opening with NSDocument
Re: Saving while opening with NSDocument
- Subject: Re: Saving while opening with NSDocument
- From: Kyle Sluder <email@hidden>
- Date: Wed, 19 Mar 2014 10:21:00 -0700
On Mar 19, 2014, at 10:11 AM, Quincey Morris <email@hidden> wrote:
>
>> On Mar 19, 2014, at 09:52 , Kyle Sluder <email@hidden> wrote:
>>
>> This doesn’t sound like a good idea to me. There is no guarantee that opening an NSDocument will cause it to create an interface—see AppleScript, printing from the Finder’s contextual menu, etc.
>
> Perhaps so, but it seems to me that there’s even less justification for re-saving the file in these scenarios than there was in the original scenario.
That’s probably a true statement, but it’s orthogonal. You should not rely on the side effect of a “nib loaded” notification to do something as fundamental as dictate your document’s data lifecycle.
Remember that it is also perfectly valid to implement -makeWindowControllers in a way that doesn’t ever touch a nib.
--Kyle Sluder
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden