• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: -[NSWindow parentWindow] for sheet never works?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: -[NSWindow parentWindow] for sheet never works?


  • Subject: Re: -[NSWindow parentWindow] for sheet never works?
  • From: Jerry Krinock <email@hidden>
  • Date: Thu, 26 Nov 2015 14:16:46 -0800

> On 2015 Nov 25, at 02:49, Graham Cox <email@hidden> wrote:
>
> I looked at the docs, saw [NSWindow -endSheet:sheetWindow] and totally misinterpreted it. I might be losing my mind, this sort of thing seems to be happening a lot lately.

Your mind is fine – you’ve just been using Cocoa for so long that you can predict what API are probably available :)   In this case, there probably *should* be such a method, a wrapper around -[NSWindow endSheet:] which plugs in self.sheet, but in this case, Apple let you down.

* * *

One more tidbit to anyone else making the conversion to the new block-based methods.  For some reason, Xcode warned me about a dozen or so NSApp beginSheet:::: methods being depredated but not about the NSApp endSheet:: methods which are also deprecated in 10.10.  In a hurry, I updated the former but not the latter.  Whoa!  It looked good in initial testing, but then I found that a dismissed sheet would *reappear later* after a different sheet was shown!  Lesson: When you update your beginSheet:::: methods, update the mating endSheet:: methods too.


_______________________________________________

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


References: 
 >-[NSWindow parentWindow] for sheet never works? (From: Jerry Krinock <email@hidden>)
 >Re: -[NSWindow parentWindow] for sheet never works? (From: Graham Cox <email@hidden>)
 >Re: -[NSWindow parentWindow] for sheet never works? (From: Quincey Morris <email@hidden>)
 >Re: -[NSWindow parentWindow] for sheet never works? (From: Graham Cox <email@hidden>)

  • Prev by Date: Re: xcodebuild and PMD
  • Next by Date: Re: xcodebuild and PMD
  • Previous by thread: Re: -[NSWindow parentWindow] for sheet never works?
  • Next by thread: Avoid selection marking on cell tap
  • Index(es):
    • Date
    • Thread