Re: how to get rid of NSSavePanel's AccessoryView's border
Re: how to get rid of NSSavePanel's AccessoryView's border
- Subject: Re: how to get rid of NSSavePanel's AccessoryView's border
- From: Nick <email@hidden>
- Date: Wed, 21 Sep 2011 22:36:31 +0300
Can't find that sheet override. I've searched everything. Used text search
either.
Here's what I've found:
Basically (as I understand) this 'you have an unsaved document. Sure to
quit?' sheet is displayed from the
- (void)saveDocumentWithDelegate:(id)delegate
didSaveSelector:(SEL)didSaveSelector
contextInfo:(void *)
method.
Interesting that in my document based application, this
-saveDocumentWithDelegate is called *only* *after *the user selected "Yes,
i'd like to save", while in TextEdit this method is invoked *before* even
the sheet appears. How did they do it to behave that way?
I also haven't found any mentioning of any of the elements of this dialog.
Neither "Do you want to save the changes you made in the document" string is
present...
2011/9/21 John Joyce <email@hidden>
> Yes TextEdit uses NSDocument, it has long been the NSDocument sample app
>
> On Sep 21, 2011, at 1:41 PM, Jens Alfke wrote:
>
> >
> > On Sep 21, 2011, at 11:28 AM, Nick wrote:
> >
> >> do you know how did Apple developers make TextEdit display a custom
> sheet for notifying that the document that's being closed needs to be saved?
> It doesn't look like an ordinary default NSDocument's "Do you want to save
> the changes you made in the document. Your changes will be lost if you don’t
> save them." sheet.
> >
> > Does TextEdit use NSDocument? It didn’t use to. But maybe it does in Lion
> to get all the fancy new save features.
> > In any case, you can look at the source code yourself; it’s one of the
> sample apps.
> >
> > —Jens_______________________________________________
> >
>
>
_______________________________________________
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