On Nov 24, 2015, at 14:54 , Graham Cox <graham....@bigpond.com> wrote: > > you close the sheet itself by sending -endSheet to the SHEET, not its parent
I’ve been puzzling over this statement for a while. At first I thought, “Oh, that’s right, you can. I guess you can send it to the sheet or the sheet’s parent window.” But then I remembered that this method has a parameter that’s the sheet window. So, I’m not sure what ‘[sheet endSheet: sheet]’ would do, if that’s what Graham meant. There’s also an [application endSheet:] method, but that’s now deprecated. In the end, I’ve come to the (possibly incorrect) conclusion, and that Graham misspoke. I think you can close the sheet with ‘[sheet orderOut: nil]’ too — at least from the completion block** — and my guess is that’s what Graham was thinking of. In fact, I think you used to be able to close the sheet with [sheet close] too, but I have a vague recollection that it crashes now, or has some other drawback. ** Sometimes the callback has to make sure the current sheet has really gone before putting up a second sheet. Of course, it’s now allowable to nest sheets, which changes the game yet again. _______________________________________________ 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